# ----------------------------------------------------------------------- # ---------------- CreateInstance EVENT ----------------------------- # ----------------------------------------------------------------------- # ON_EVENT "CreateInstance" { # SETG id_InstId: (instid) # SETG id_ClassId: (classid) # SETG id_ModelId: (modelid) # SETG id_RealClassId: (realclassid) # SETG id_RealInstId: (realinstanceid) # } CC "Core" GET_CLASS_ID classname: "Task" SET n_TaskClassId: (classid) IF (n_TaskClassId = id_ClassId) { # ---- Get the Attribute value of instanced object with Attributename "Position" and Set the result to "s_startPosition" CC "Core" GET_ATTR_VAL objid:(id_InstId) attrname:"Position" #-->RESULT ecode:intValue val:anyValue SET s_startPosition: (val) # ---- Set value of "s_startPosition" to the Attribute Value of Attribute "StartPosition" CC "Core" SET_ATTR_VAL objid:(id_InstId) attrname:"StartPosition" val:(s_startPosition) #-->RESULT ecode:intValue # ---- Get the Attribute value of Attribute "Accept all changes to object" and set the result to "v_Accept all changes to objectVal" CC "Core" GET_ATTR_VAL objid: (n_instId) attrname: "Accept all changes to object" SET SET v_Accept all changes to objectVal: (val) # ---- Set the Attribute value of Attribute "Accept all changes to object" to "Yes" CC "Core" SET_ATTR_VAL objid: (n_instId) attrname: "Accept all changes to object" val:"Yes" #-->RESULT ecode:intValue attrid:id } PROCEDURE GET_OBJECT_POSITION objectid: integer param_val: reference { CC "Core" GET_CLASS_ID objid: (objectid) #--> RESULT ecode: intValue classid: intValue isrel: intValue SETL id_class_id_local: (classid) CC "Core" GET_ATTR_ID classid: (id_class_id_local) attrname: ("Position") #--> RESULT ecode: intValue attrid: id SETL id_attribute_id_local: (attrid) CC "Core" GET_ATTR_VAL objid: (objectid) attrid: (id_attribute_id_local) #--> RESULT ecode: intValue val: anyValue SETL param_val: (val) }