Download presentation
Presentation is loading. Please wait.
Published byGerald Price Modified over 9 years ago
1
Modern Aspects in Software Engineering 4. Object-Oriented SE Prof. Dr
Modern Aspects in Software Engineering 4. Object-Oriented SE Prof. Dr.-Ing. habil. Reiner Dumke Otto-von-Guericke-Universität Magdeburg Fakultät für Informatik, Institut für Verteilte Systeme AG Softwaretechnik
2
OOSE - Introduction Functions or functional structures,
Interfaces between the system components, Functions or functional structures, Data basis and/or data structures, Problem related objects. Changing
3
OOSE - Introduction Effectiveness of Programming: Simula 67 Smalltalk
Eiffel etc.
4
OOSE - Introduction Abstract data types opns 0,1: Bit
type Bit is Boolean opns 0,1: Bit + : Bit, Bit Bit eq: Bit,Bit Boolean eqns 0 + 1 = = 1 1 + 1 = = 0 0 eq 0 = 1 eq 1 = true 1 eq 0 = 0 eq 1 = false endtype
5
OOSE - Introduction Basic notions:
Object: abstraction of the problem area with states (attributes) and behavior (services/methods) Message: a call of a service of an object in the form method(par1, …, parn) Role: the possible behavior of an object in a special context Scenario: a sequence of messages which explain the operationality
6
OOSE - Introduction Basic notions:
Class: a summarizing of objects with semantical equivalency Class hierarchy: inheritance structure (mostly: tree) Class library: an implemented set of classes Polymorphism: the possibility of two or more methods with the same name
7
OOSE - Introduction Class diagram: Book title author Cover keywords
displayContents SEBook TextBook pages
8
OOSE – Development Methodologies
9
OOSE – Analysis & Specification
Dear Developer, I like to count. I want to have a software system for counting including incrementing and decrementing. I want to count a lot of things in different number systems. Just I have a red plastic counter with an increment button, a decrement button and – I see – a reset button. Best regards Your customer
10
OOSE – Analysis & Specification
Number countValue resetValue reset increment decrement presenting Not counter!
11
OOSE – Analysis & Specification
Analysis pattern: Party Portfolio Post Contract Scenario etc.
12
OOSE - Design Number countValue resetValue MyCounter reset + - R
increment decrement presenting MyCounter R display
13
OOSE - Design
14
OOSE – Design Pattern
15
OOSE – Implementation (Java)
16
OOSE – Implementation (Forte4J)
17
OOSE – Implementation (Forte4J)
18
OOSE - Implementation
19
OOSE - Testing Classical test example: All Ci cases and all numbers:
Java-Code: for (int i=0; i < n; i++) { if (a.get(i) == b.get(i)) x[i] = x[i] + 100; else x[i] = x[i]/2; } All Ci cases and all numbers: Billion of years test time
20
OOSE - Testing Test example 2: Proof if a, b, c builds a triangle
21
OOSE - Testing Added test cases: missing constructor
overwritten methods overloaded attributes incorrect inheritance inheritance cycle missing class variables etc.
22
Test Pattern Description
OOSE – Test Pattern Test Pattern Description Intent Context Fault Model Strategy Entry/Exit Criteria Consequences Known uses
23
Test Design Pattern - Examples
OOSE – Test Pattern Test Design Pattern - Examples Test area Identification Content Class methods Category-Partition Test case for I/O Combinational Function Logical based test sequences Recursive Function Test cases for recursive funktions Polymorphic Message Test cases for a client to a pol. server Classes Invariant Boundaries Identification of test vectors Nonmodal Class Class test cases without constraints Quasi-modal Class Class test cases with constraints Transitive Operation Test cases for transitive methods Class integration … Components … System … Application …
24
OOSE – Unified Modeling Language
25
OOSE – Rational Unified Process
26
OOSE – UML - OCL Object Constraint Language (OCL):
Typ1::operation(arg : Typ2) : ReturnTyp pre : arg.attribut1 = true post: result = arg.attribut1 xor arg.attribut2 Customer sex = #female implies calling=‘Senior‘
27
OOSE – UML - CASE
28
OOSE – UML - CASE
29
OOSE – UML - CASE
30
OOSE – UML - Example Housekeeping Book
31
Housekeeping Book – Behavior modelling
OOSE – UML - Example Housekeeping Book – Behavior modelling
32
Housekeeping Book – Component design
OOSE – UML - Example Housekeeping Book – Component design
33
OOSE – UML - Example Housekeeping Book – Implementation characteristics: Number of Requirements: 20 verbal description, Test cases: 28 , Diagrams: 1 Use Case diagram, 8 State diagrams, 4 Sequence diagrams, 4 Collaboration diagrams, 3 Class diagrams, 1 Component diagram, Algorithm description: ca. 150 Lines of pseudocode, Classes: 21 implemented Java Classes, Program lines: ca Java LOC, Dokumentation: Web-based hypertext description Effort: ca. 3 Person month
34
Questions, Remarks !!!
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.