Re: OCL Question



Date view Thread view Subject view Author view

Jos Warmer (J.Warmer@klasse.nl)
Sun, 28 Oct 2001 20:45:43 +0100


At 06:46 PM 26/10/01 -0400, Les Munday wrote: >I'm trying to demonstrate how to represent class operations in >UML. Do you mean "class operations" which are performed by the class instead of the instance (like static operations in C++ or Java)? This doesn't show in your exaples. >I have a template I use that is of the format: > >Precondition -> Stimulus -> {Action} -> Postcondition -> Time. > >The precondition describes the state the system must be in >prior to the operation occuring. > >The stimulus is an event that triggers the operation. > >The action describes the process that occurs a result of the >event occuring {and is optional}. > >The postcondition is the state that the system is in at the >completion of the operation. > >Time is the maximum time for the operation to complete. > >So far I have: > >context ClassName::OPerationName::ReturnResult >pre olcInState() >post ActionResult and oclInState() > >Any ideas how to reference an event from my model and how to >specify time to execute in OCL? If the event is the cause of the operations, should the operation get the event as one of its parameters? If not, UML doesn't define how to "access" an event. In UML an event can be many things, e.g an operation call or a receipt of a signal. What kind of event do you want to refer to? >Any references to OCL examples would be helpful. > >Thanks, > >Leslie. Regards, Jos Warmer _____________________________________________________ Klasse Objecten tel : +31 (0)35 6037646 Chalonhof 153 fax : +31 (0)35 6037647 3762 CT Soest email : J.Warmer@klasse.nl The Netherlands internet: http://www.klasse.nl


Date view Thread view Subject view Author view