StateMachine Composite Structure Sequence

Save this PDF as:
 WORD  PNG  TXT  JPG

Size: px
Start display at page:

Download "StateMachine Composite Structure Sequence"

Transcription

1 SMART0.3 UML Modeler version SMART main 4 3 UML Modeler STT 4 4 UML SMART UML Modeler logical gui model ui view factory Model SmartClass AttributeList OperationList EventList parent( )

2 StateMachine Composite Structure Sequence User Interface UseCase Activity Activity dump/restore Save/Load Instanciation User Interface Model SubModel User Interface UML Sequence Composite Structure Suggestion SMART0.3 eclipce UML2.0 2

3 Fig 1: SMART Package commonbehavior action SMART0.2 Statement.java communications SMART Test Tool(STT) UML Modeler MissingElement core RuntimeInstance SMART0.2 dump restore Dump Restore Instanciation User Interface dump testtool STT 3

4 traceability SMART Traceability Web Tool(STWT) tracer Sequence Composite Structure Logger.java uml UML2.0 (SMART ) umlmodeler logical 4 umlmodeler SMART0.2 Statechart Modeler UI(User Interface) Modeler UML Modeler Composite Structure dump/restore 5 2 main SMART0.3 main 4 1. smart.main 2. smart.testtool.swingui.testrunner 3. smart.traceability.gui.traceabilitytool 4. smart.umlmodeler.umlmodeler SMART smart.main main 3 UML Modeler STT SMART Test Tool UML Modeler smart.communications 4 UML2.0 smart.uml UML2.0 Superstructure Specification(http: // 4

5 smart.uml UML2.0 spec UML Java smart.uml I ( Operation IOperation ) Attribute Association Spec Attribute Association get/set 1 collection spec Operation Attributes. class : Class [0..1]. /isordered : Boolean ( ) Associations ( ). bodycondition: Constraint[0..1] ( ) interface IOperation{ } public IClass getclass(); public void setclass(iclass class_); public boolean isordered(); public void setordered(boolean ordered); public Collection getbodyconditions(); //Collection set 5

6 5 SMART UML Modeler UML Modeler smart.umlmodeler UML Modeler ( STT STWT ) Fig 2: SMART UML Modeler 6

7 5.1 Fig 3: smart.umlmodeler packages logical smart.uml (4 ) gui UML Modeler GUI model swing smart.umlmodeler.gui UML Modeler (UmWindow) InstanceWindow smart.umlmodeler.gui.action action UML Modeler EditToolBar smart.umlmodeler.gui.action.command smart.umlmodeler.gui.action save/load action Command dump activity usecase save/load 7

8 smart.umlmodeler.gui.command SMART0.2 smart.viewmodel.statechart.command Command ModelExecutionCommand UML Modeler smart.umlodeler.gui.dialog Dialog smart.umlmodeler.gui.handler (StateMachine Composite Structure Sequence ) SMART0.2 smart.statechartmodeler handler smart.umlmodeler.gui.visitor accepter (TreeNode accepter ) model Model ui SMART0.2 UI Modeler User Interface view UML Sequence Lifeline logical MLifeline view LifelineView factory 5.2 Model Model 8

9 Fig 4: SMART Model and SmartClass 1. Model Classifier (SmartClass ) 2. Model 3. bool 4. bool 5. Model 6. Model Instance 5.3 SmartClass SmartClass AttributeList Classifier Attribute UML2.0 Property Property SMART Property value Attribute Slot Property isslot boolean isslot false 9

10 5.3.2 OperationList Classifier Operation SMART EventList Classifier Event Event Trigger CallTrigger SignalTrigger ChangeTrigger TimeTrigger AnyTrigger SMART0.2 Statechart Modeler StateMachine Event EventList Event StateMachine Event EventList parent( ) SMART0.3 User Interface SmartClass SmartClass null User Interface User Interface SmartClass 5.4 SMART StateMachine SMART0.2 Statechart Model 1 StateMachine StateMachine StateMachine smart.umlmodeler.logical.state_machines 10

11 UML1.X SMART0.3 UML1.X abort Composite Structure UML2.0 Composite Structure port Class Composite Structure Collaboration Composite Structure Model Composite Structure 1 Composite Structure Composite Structure Composite Structure Fig5 CompositeStructure Fig 5: Composite Structure Toolbar smart.uml.composite_structures smart.umlmodeler.logical.composite_structures smart.umlmodeler.factory.composite_structures smart.umlmodeler.view.composite_structures Composite Structure StateMachine StateMachine 11

12 5.4.3 Sequence UML2.0 UML2.0 Sequence Sequence Lifeline Composite Structure Parts Model Sequence User Interface UseCase UseCase 5.5 Activity SMART0.3 Activity SMART Activity Activity Model Acitivity Model Activity Acitity Fig2 Acitivity Activity Activity Activity Activity Activity Modeler 5.6 dump/restore XML 12

13 5.7 Save/Load dump/restore Save/Load activity usecase dump.xml activities On... usecases usecase Instanciation Model Model Instance dump Model (createinstance) 5.9 (regenerateinstances ) Model bool isexecution true 5.10 User Interface SMART0.2 UI Modeler User Interface SMART Model 5 User Interface Model(UI Model) 1. TextLabel 13

14 2. TextButton 3. ImageLabel 4. ImageButton 5. TransparentButton UI Modeler UI Parts SMART smart.umlmodeler.builtinuimodelcreater Fig2 Model SubModel User Interface Model Sub- Model (Model createsubmodel) createsubmodel createinstance Model parent UI Model User Interface SMART0.2 UI Modeler UIParts (ImageLabel ) SMART0.3 UIParts UI Model User Interface 5.11 UML2.0 4 smart.uml implement smart.umlmodeler.logical get/set M 4 IOperation MOperation class MOperation implements IOperation{ private IClass class_; private boolean isordered=false; private Collection bodyconditions=new HashSet(); public IClass getclass(){...}; 14

15 } public void setclass(iclass class_){...}; public boolean isordered(){...}; public void setordered(boolean ordered){...}; public Collection getbodyconditions(){...}; smart.uml smart.umlmodeler.logical UML Java UML Java smart.uml /*extends XXX*/ StructuralFeature Feature TypedElement MultiplicityElement 3 public interface IStructualFeature implements IFeature,ITypedElement,IMultiplicityElement{... } public abstract class MStructuralFeature extends MFeature implements IStructuralFeature {... } UML2.0 spec abstract abstract spec abstract spec Chapter abstract syntax StateMachine logical StateMachine SMART UML1.X 15

16 2. logical view smart.tracer Sequence smart.tracer.composite checker Composite Structure STT run 2. UML Modeler Logger Logger clearlog trace.log 10 :TransitionID TransitionID Transition smart. umlmodeler. logical. state machines. behavior state machines TransitionView dump SMART event-activity-execute-begin 16

17 event-activity-execute-begin: activity, activity StateMachine Object. activity TransitionID activity event-activity-execute-begin:, body.transition10 event-activity-execute-end event-activity-execute-:activity activity acitivity begin-testcase begin-testcase: testcase, TestCase Run begin-testcase:testcase,2004/1/4/7:51 end-testcase end-testcase: testcase, TestCase Run assert-equals assert-equals:, assertion,,, assertion {false,true} STT assertion SAL assertequals(, assertion ) assert-equals:24,aircon. [0],24,21,false assert-true assert-true: assertion, assertion {false,true} assertion SAL asserttrue( assertion ) 17

18 failed-by-meerror failed-by-meerror: testcase TestCase MEError setcurrent-state setcurrent-state: Object. State, setcurrent SAL setcurrent setcurrent-state:body. on,testcase2 iscurrent-state iscurrent-state: Object. State, iscurrent, assertion {false,true} SAL iscurrent iscurrent-state:body. on,testsuiteroot\ \testcase3,false message-send-call-event message-send-call-event: event, callevent,,, Event argument[ ] SAL callevent message-send-call-event:,testsuiteroot\ \testcase2,testcase2,aircon,[23] message-send-return-event message-send-return-event: event, callevent,, message-send-call-event return message-send-call-activity message-send-call-activity: activity, callactivity activity SAL callactivity message-send-call-activity:,testsuiteroot\ \testcase 18

19 message-send-return-activity message-send-return-activity: activity, callactivity message-send-call-activity return read-attribute read-attribute: Object., read, read-attribute write-attribute write-attribute: Object., (String ), (String ),,, write-attribute write-attribute:controller., controller. [0], 23,23, 23, testsuiteroot\ \testcase1, testsuiteroot\ \testcase1 transtion-begin transition-begin: transitionid transtion-end transition-end: transitionid [ ] [A,B,C,...] [] (ConcurrentSAL ) 19

20 6.3 Sequence Fig2 Tracer Sequence TestCase 2 Sequence smart.umlmodeler.logical (smart.umlmodeler.logical.extensions) TestCase TestCase Object Sequence Object TestCase Lifeline Sequence Sequence UML Composite Structure Sequence Composite Structure CompositeStructureChecker Fig 6: Composite Structure Checking Check 20

21 suggestion smart.tracer Logger.java write open/close STT STT STT UML Modeler 2 Open Close flush Fig 7: AbstractWindow AbstractWindow UMLModeler UmWindow InstanceWindow ModelScreen(smart.umlmodeler.gui ) ModelScreen 21

22 AbstractWindow AbstractWindowListener windowgainedfocus ModelScreen 7.2 UseCase StateMachine Model activity usecase (STT activity ) Suggestion Composite Structure Sequence suggestion Composite Structure Connector Sequence Message Connector Message suggest 8 pdf 22

23 9 ( ) 23