composite structure diagram luca colombi. abstract uml 2.0 composite structure diagram basic...
TRANSCRIPT
![Page 1: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/1.jpg)
Composite Structure Diagram
Luca Colombi
![Page 2: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/2.jpg)
AbstractUML 2.0 composite structure diagramBasic concepts
Structure, structured entity, internal structureElements
PropertyConnectorNested notation
Description powerClasses & Structured Classes
Instance specificationNamespace behaviour
CollaborationPurpose
RolesRole binderCollaboration Occurrence
Occurrence binder<<occurrence>> & <<represent>>
PortVisibilityInterfaces
Examples
![Page 3: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/3.jpg)
UML 2.0 diagram
Classified in UML 2.0 structural diagramsNew:this diagram was not available in UML 1.*
![Page 4: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/4.jpg)
Purpose
Composite structure diagrams can be used to describe:
structures of interconnected partsrun-time structures of interconnected instancesExample:Description of the parts of an engine that are interconnected to perform the engine functioning
![Page 5: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/5.jpg)
Structure
A set of instances that communicate and collaborate at run-time to realize a common goal
Ex.: net routers that realize a particular journey
Structured element:An element realized by a structure
Ex.: a net realized by routers
Internal structure:A structure that realize a structured element
Ex.: all the routers in a net
![Page 6: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/6.jpg)
PropertyA set of instances contained in a structured instance
roleName:TypeName
ms:MailSender
ms:MailSender
sendMail(…)
MailSender
role of the property instances for the container (optional)type or class of the property instances (obligatory)
![Page 7: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/7.jpg)
Connector
Represents the visibility between two property a communication way
w:Well
e:EngineconnName:ConnTyperoleName1 roleName2
[Multeplicity1] [multeplicity2]
a:Axis
2
1
role multeplicity (optional)
role name (optional)connector name (optional)
connector type (optional)
proprerty
![Page 8: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/8.jpg)
Nested notation
Composite structure diagrams allows to use class diagram-like or nested notationIt is permitted to recursively nest already nested entitiesContainer
Container
contained3:Inner3
contained2:Inner2[n2]
contained1:Inner1[n1]
contained3:Inner3
contained2:Inner2
contained1:Inner1property
multeplicity (integer, optional)
inner dash ifnot a composition
![Page 9: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/9.jpg)
Structured Class: example
Recursive application of nested notation can be done inside a single diagram
RoomContents
john:Mangeranium:Plant
Leaf[*] Trunkheight:real
![Page 10: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/10.jpg)
Description power
Nested notation can describe all things describable in 1.* class diagrams notation, and a little more
Car
Wheel Engine
Car
**Axis
w:Wheel[4] e:Enginea:Axis
2 1e12w
![Page 11: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/11.jpg)
Instance specification
describes the property which is returned by an operation call, the operation is pointed by the arrow at the end of a dashed line that starts from the returned type description
Room
createChair(…) getWindow(…)
c:Chair
<<create>> is an optional label and specify that label exists only after the operation call
w:WindowLeg[4]
<<create>>
![Page 12: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/12.jpg)
Namespace behaviour
A structured class acts as a namespace for its internal descriptions, so descriptions are not implicitly exported
![Page 13: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/13.jpg)
Collaboration
A joining of structure elements that collaborate to collectively perform a task
CollaborationName
CollaborationName
Used in nested notationThe name given to the collaboration (obligatory)
![Page 14: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/14.jpg)
Collaboration purpose
A collaboration wants to describe a structure behaviour made by structure propertyMust be connected only with property which are required to perform its described behaviour
![Page 15: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/15.jpg)
Collaboration role
property which collaborate to perform the collaboration goal, interpreting rolesEach collaboration role perform a specific task
Counting of clients
ClientCard
name:Stringaddress:String…
“Counting of clients” have some ClientCard as roles
![Page 16: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/16.jpg)
Collaboration Role Binder
represent a participation of the role to the collaboration
Pilot
Car
Drive a car
roleName
the name given to the role
property
collaboration
![Page 17: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/17.jpg)
Collaboration Occurrence
A specific collaboration instance
occName:CollName
used in nested notation
occName:CollName
name of the instance (obligatory)
type of the instance (obligatory)
send:MailSend
![Page 18: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/18.jpg)
Occurrence binderBinds an occurrence to a role, maybe specifing how many occurrence repetitions are present
occName:CollName RoleTyperoleName[n]
occName:CollName
roleName:RoleType
[n]
sellProduct:Selljohn:Countryman
Egg
role name (optional)role multeplicity (optional)
selled[12]
![Page 19: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/19.jpg)
Example: occurrence - Send mail
send:Send an email
Sender Receiver
mailServer[2][1] [1]
![Page 20: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/20.jpg)
<<occurrence>> label
A dashed arrow between two symbol of same type means that pointing symbol represent pointed symbol, like in a specialization
Send email<<occurrence>>
Communicate
Home<<occurrence>>
Building
<<occurrence>> label is optional
![Page 21: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/21.jpg)
<<represent>> label
client:CurrentAccount
accredit(…)deposit:Increase amount
<<represent>>
A dashed arrow from a collaboration or an occurrence to a property means that property use the other instance, like a client or a use case primary actor
<<represent>> label is optional
![Page 22: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/22.jpg)
Occurrence binding nest crossing
Occurrence binding is admitted between separately nested elements with also have occurrence bindings
d:dealerp:producer
products transport putting on shelf
![Page 23: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/23.jpg)
Port
represent a property communication point, and is always placed where the property joins whit its connectortwo types of communications:
Between a property and its external environmentBetween a property and its internal structure
![Page 24: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/24.jpg)
Ports: visibility markingIf port symbol cover a rectangle boundary his visibility is publicIf port symbol is placed inside a rectangle, adjacent to his boundary, his visibility is protected
portName:EntityName[n]
portName:EntityName[n]
port instance name (optional)
port type (optional)
port multeplicity (optional)
Computer
User
m:Monitor[1]property
![Page 25: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/25.jpg)
Ports: interfaces
An interface exported by a port is a little circle (interface symbol) connected with the port symbol by a lineAn interface needed by a port is a little semicircle (socket symbol) connected with the port symbol by a lineIf interface is present, interface type is signed near interface symbol
![Page 26: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/26.jpg)
Ports: interfaces examples
Apache
SqlSrv
HttpSrvc
sqlServer
httpService [100]
Apache
SqlSrv
sqlServer[1]
httpService:HttpSrvc [100]
Apache
sqlServer:SqlSrv [1]
httpService:HttpSrvc [100]
![Page 27: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/27.jpg)
Example: Port
Structure with many kinds of connectors and ports:
StudentRoom
:Key[101]
Keyboard
StudentComputer
p:RoomDoor
w:Window
Monitor
![Page 28: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/28.jpg)
Example: structured class - House
House
Kitchen Bath
Hall
Passage
Bedroom[2] [1][1]
:Door:Window
:Window[2]
:Window[1]
:Window:Window
![Page 29: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/29.jpg)
Example:collaboration - Drive a taxi
Drive a taxy
john:TaxyDriver
kate:Passenger
Body
Head
Leg[2] Bust Arm[2][2] [2]
Car
Well[4] Engine[2]
GE_553912:Taxy
:SteeringWheel [1]
[0..5]place:Seat
![Page 30: Composite Structure Diagram Luca Colombi. Abstract UML 2.0 composite structure diagram Basic concepts Structure, structured entity, internal structure](https://reader035.vdocuments.us/reader035/viewer/2022062313/56649c985503460f94953ea0/html5/thumbnails/30.jpg)
References
OMG official site for UML:http://www.uml.org
Agile software association Composite structure diagrams: http://www.agilemodeling.com/artifacts/compositeStructureDiagram.htm