123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- include "primitives.alh"
- SimpleClassDiagrams Plant_PW{
- SimpleAttribute String {
- constraint = $
- String function constraint(model : Element, name : String):
- if (is_physical_string(model["model"][name])):
- return "OK"!
- else:
- return "String has non-string value"!
- $
- }
- Class Named {
- name : String
- }
- Class Port {
- name : String
- }
- Class Switch : Named {}
- Class Boundary : Named {}
- Class PowerWindow : Named{}
- Class Sensor : Named {}
- Class Movement : Switch {}
- Class LockOut : Switch {}
- Class Infrared : Sensor {}
- Class ForceDetecting : Sensor {}
- Class Rocker : Movement {}
- Class PushPull : Movement {}
- Class Side : PowerWindow{}
- Class Roof : PowerWindow{}
- Association ConnectSwitch (Port, Switch) {}
- Association has1 (Boundary, Switch) {}
- Association Controls (Movement, PowerWindow) {}
- Association HasSwitch (PowerWindow, Switch) {}
- Association Locks (LockOut, PowerWindow) {}
- Association HasSensor (PowerWindow, Sensor) {}
- Association Around (Boundary, PowerWindow) {}
- Association Interface (Boundary, Port) {}
- Association ConnectSensor (Port, Sensor) {}
- Association has2 (Boundary, Sensor) {}
- }
|