public class ASME2SSME_Translate_Common extends ASME2SSME_Translate_Feature
ACTUAL_CONNECTION_BINDING_ID, ACTUAL_LATENCY_ID, ACTUAL_MEMORY_BINDING_ID, ACTUAL_PROCESSOR_BINDING_ID, CLOCK_PERIOD_ID, COMPUTE_EXECUTION_TIME, COMPUTE_EXECUTION_TIME_PROPERTY_ID, DEADLINE_ID, DEQUEUE_PROTOCOL_ID, DEQUEUE_PROTOCOL_PROPERTY_ID, DEQUEUED_ITEMS_ID, DEQUEUED_ITEMS_PROPERTY_ID, DEVICE_DISPATCH_PROTOCOL_ID, DISPATCH_PROTOCOL_ID, DISPATCH_PROTOCOL_PROPERTY_ID, FAN_OUT_POLICY_ID, FLOWLATENCY_ID, FROZEN_TIME_EVENT_ID, INPUT_TIME_PROPERTY_ID, INPUT_TIME_REFERENCE_TIME_ID, INPUT_TIME_REFERENCE_TIME_PROPERTY_ID, LATENCY_ID, LATENCY_PROPERTY_ID, LATENCY_TIME_EVENT_ID, OUTPUT_TIME_EVENT_ID, OUTPUT_TIME_PROPERTY_ID, OUTPUT_TIME_REFERENCE_TIME_ID, OUTPUT_TIME_REFERENCE_TIME_PROPERTY_ID, OVERFLOW_HANDLING_PROTOCOL_ID, OVERFLOW_HANDLING_PROTOCOL_PROPERTY_ID, PERIOD_ID, PERIOD_PROPERTY, PRIORITY_ID, PROPERTY_ID, QUEUE_PROCESSING_PROTOCOL_ID, QUEUE_PROCESSING_PROTOCOL_PROPERTY_ID, QUEUE_SIZE_ID, QUEUE_SIZE_PROPERTY_ID, READ_TIME_ID, READ_TIME_PROPERTY_ID, REFERENCE_TIME_EVENT_ID, SUPPORTED_DISPATCH_PROTOCOLS, TIME_OFFSET_ID, TIME_OFFSET_PROPERTY_ID, TIME_UNITS_ID, TIMING_ID, TIMING_PROPERTY_ID
ALARM_ID, COMPLETE_ID, COMPLETION_ID, CTL1_ID, CTL2_ID, DISPATCH_ID, ERROR_ID, NameList, RESUME_ID, START_ID, TIME1_ID, TIME2_ID, TOP_ID, TREAD_ID, TRESET_ID, TWRITE_ID
Constructor and Description |
---|
ASME2SSME_Translate_Common()
Class constructor
|
Modifier and Type | Method and Description |
---|---|
void |
ASME2SSME_add_Declaration_to_ProcessType_Interface(java.lang.String name,
java.lang.String type,
ProcessModelImpl vprocess,
SignalElementImpl mmodel,
int i)
Adds a signal declaration to a ProcessType (which represents an AADL process type component) interface.
|
void |
ASME2SSME_add_IDInterface_to_Process(ProcessModelImpl vprocess,
java.lang.String id_name)
Adds an interface to a process (vprocess),
where the interface is an identifier with a name (id_name)
|
void |
ASME2SSME_add_input_to_process_interface(java.lang.String name,
java.lang.String type,
ProcessModelImpl vprocess)
Adds an input signal to an interface of a Singal process.
|
void |
ASME2SSME_add_output_to_process_interface(java.lang.String name,
java.lang.String type,
ProcessModelImpl vprocess)
Adds an output signal to an interface of a Singal process.
|
SignalsDeclarationImpl |
ASME2SSME_BehavioredImpl_SubprogramSubcomponent1(org.osate.aadl2.SubprogramSubcomponent sub_sp,
org.osate.aadl2.BehavioredImplementation t)
Translates a subprogram subcomponent (x: subprogram sp) of a thread (or subprogram) t
as an input event: event x,
|
void |
ASME2SSME_component_instance(ProcessModelImpl vprocess,
ProcessModelImpl pprocess,
java.lang.String label)
Makes a process call of a component Signal process, and adds it to the upper level's Signal process's body.
|
ProcessModelImpl |
ASME2SSME_ComponentImpl_Flows(org.osate.aadl2.ComponentImplementation c)
Translates flow implementations.
|
void |
ASME2SSME_ComponentImpl_Modes(org.osate.aadl2.ComponentImplementation c)
Translates modes
|
void |
ASME2SSME_ComponentInterface_CallSubprograms(ProcessModelImpl vprocess,
org.osate.aadl2.BehavioredImplementation t)
Translates call subprogram sp as outputs of vprocess's interface (is sp is not a subcomponent of itself).
|
void |
ASME2SSME_ComponentInterface_DataAccess(ProcessModelImpl vprocess,
org.osate.aadl2.ComponentType st)
Translates requires data access feature as outputs of vprocess's interface:
FIFO_TIME xx;
|
void |
ASME2SSME_ComponentInterface_Sub_Subprograms(ProcessModelImpl vprocess,
org.osate.aadl2.BehavioredImplementation t)
For the sub subprograms of a thread (t):
For each sub subprogram x: subprogram sp,
add into the interface: ?
|
void |
ASME2SSME_ComponentInterface_SubprogramAccesses(ProcessModelImpl vprocess,
org.osate.aadl2.ComponentType st)
Translates requires subprogram access feature as outputs of vprocess's interface:
event xx;
|
void |
ASME2SSME_ComponentInterface(ProcessModelImpl vprocess,
org.osate.aadl2.ComponentType st)
Creates a Signal process interface from a component type,
and add the interface to the Signal process.
|
ProcessModelImpl |
ASME2SSME_ComponentType_FlowSpecs(org.osate.aadl2.ComponentType t)
Translates flow specifications.
|
void |
ASME2SSME_ComponentType_Modes(org.osate.aadl2.ComponentType c)
Translates modes and mode transitions.
|
void |
ASME2SSME_DataAccess_local(ProcessModelImpl vprocess,
org.osate.aadl2.ComponentType st)
Creates two local signals for each requires data access xx in vprocess (a thread):
shared integer xx_w, xx_r;
|
boolean |
ASME2SSME_Process_Interface_Contain_Signal(ProcessModelImpl vprocess,
java.lang.String sig_name)
Returns a boolean value that indicates whether a signal (named sig_name) exists in the I/O interface of a process (vprocess)
|
java.lang.String |
Generate_Signal_comment(java.lang.String signal_name)
Returns a string that comments a signal
|
java.lang.String |
GetDateNow()
Returns the current date in the form of yyyy/MMM/dd HH:mm:ss
|
ASME2SSME_BusAccess, ASME2SSME_DataAccess, ASME2SSME_DataPort, ASME2SSME_EventDataPort, ASME2SSME_EventPort, ASME2SSME_Parameter, ASME2SSME_Port, ASME2SSME_RequiresDataAccess_Bundle, ASME2SSME_RequiresDataAccess_ReadTime, ASME2SSME_RequiresDataAccess_reset, ASME2SSME_RequiresDataAccess_WriteTime, ASME2SSME_RequiresSubprogramAccess_call, ASME2SSME_SubprogramCall1
ASME2SSME_Actual_Connection_Binding_Property, ASME2SSME_Actual_Memory_Binding_Property, ASME2SSME_Actual_Processor_Binding_Property, ASME2SSME_ActualLatency_Property_Call, ASME2SSME_Clock_Period_Property, ASME2SSME_Component_Properties_Call, ASME2SSME_Deadline_Property, ASME2SSME_Dequeue_Protocol_Property_Call, ASME2SSME_Dequeue_Protocol, ASME2SSME_Dequeued_Items_Property_Call, ASME2SSME_Dequeued_Items, ASME2SSME_Device_Dispatch_Protocol_Property, ASME2SSME_Device_property_call, ASME2SSME_Dispatch_Protocol_Property, ASME2SSME_Fan_Out_Policy_Property_Call, ASME2SSME_FlowLatency_Property_Call, ASME2SSME_Input_Time_Reference_Time_Property_Call, ASME2SSME_InputTime, ASME2SSME_Latency_Property_Call, ASME2SSME_Output_Time_Reference_Time_Property_Call, ASME2SSME_OutputTime, ASME2SSME_Overflow_Handling_Protocol_Property_Call, ASME2SSME_Overflow_Handling_Protocol, ASME2SSME_Period_Property, ASME2SSME_Priority_Property_Call, ASME2SSME_Property_Call_withName, ASME2SSME_Property_Call, ASME2SSME_PropertySet, ASME2SSME_Queue_Processing_Protocol_Property_Call, ASME2SSME_Queue_Processing_Protocol, ASME2SSME_Queue_Size_Property_Call, ASME2SSME_Queue_Size, ASME2SSME_Read_Time_Property, ASME2SSME_Source_Name, ASME2SSME_Time_Offset_Property_Call, ASME2SSME_Time_Unit_ConstantEnum, ASME2SSME_Timing_Property_Call, ASME2SSME_Timing, Name_of_Reference_data_classifier, read_PropertyAssociation
Generate_Process_Instance_comment, Get_top_sname, getSname, Name_of_Bus, Name_of_Connection, Name_of_CTL1_type, Name_of_CTL2_type, Name_of_Data, Name_of_DataBundle, Name_of_DataReadTime, Name_of_DataReset, Name_of_DataType, Name_of_DataWriteTime, Name_of_Device, Name_of_FeatureGroup, Name_of_FeatureGroupType, Name_of_Flow, Name_of_Local_Signal, Name_of_Memory, Name_of_ParameterConnection, Name_of_PortGroup, Name_of_PortGroupType, Name_of_Process, Name_of_Processor, Name_of_Subprogram_Struct_In, Name_of_Subprogram_Struct_Out, Name_of_Subprogram, Name_of_SubprogramCall, Name_of_System, Name_of_Thread, Name_of_ThreadDataPort, Name_of_ThreadEventDataPort, Name_of_ThreadEventPort, Name_of_ThreadTimeBundle, Name_of_TriggerDispatch_Event, Name_of_Type_Process, Trace
public java.lang.String GetDateNow()
public void ASME2SSME_ComponentInterface(ProcessModelImpl vprocess, org.osate.aadl2.ComponentType st)
vprocess
- a Signal process representing this component (implementation)st
- a component type componentpublic void ASME2SSME_ComponentInterface_DataAccess(ProcessModelImpl vprocess, org.osate.aadl2.ComponentType st)
vprocess
- a Signal process representing this component (implementation)st
- a component type componentpublic void ASME2SSME_DataAccess_local(ProcessModelImpl vprocess, org.osate.aadl2.ComponentType st)
vprocess
- a Signal process representing a threadst
- a component type componentpublic void ASME2SSME_ComponentInterface_SubprogramAccesses(ProcessModelImpl vprocess, org.osate.aadl2.ComponentType st)
vprocess
- a Signal process representing this component (implementation)st
- a component type componentpublic void ASME2SSME_ComponentInterface_CallSubprograms(ProcessModelImpl vprocess, org.osate.aadl2.BehavioredImplementation t)
vprocess
- a Signal process representing component (implementation) tt
- a component implementation (thread or subprogram impl) that contains subprogram call sequencespublic void ASME2SSME_ComponentInterface_Sub_Subprograms(ProcessModelImpl vprocess, org.osate.aadl2.BehavioredImplementation t)
vprocess
- a Signal process representing component (implementation) tt
- a component implementation (thread or subprogram impl)public ProcessModelImpl ASME2SSME_ComponentType_FlowSpecs(org.osate.aadl2.ComponentType t)
t
- public void ASME2SSME_ComponentType_Modes(org.osate.aadl2.ComponentType c)
c
- public void ASME2SSME_ComponentImpl_Modes(org.osate.aadl2.ComponentImplementation c)
c
- public ProcessModelImpl ASME2SSME_ComponentImpl_Flows(org.osate.aadl2.ComponentImplementation c)
c
- public void ASME2SSME_add_input_to_process_interface(java.lang.String name, java.lang.String type, ProcessModelImpl vprocess)
This input signal is given by a String name, and a String type. Creates a signal declaration by a method STree_mkSignalDeclaration(), and adds it to the process's interface by STree_addDeclarationToInterface().
name
- a String name of the input signaltype
- a String type name of the input signalvprocess
- a Signal process where this input signal is to be added intopublic void ASME2SSME_add_output_to_process_interface(java.lang.String name, java.lang.String type, ProcessModelImpl vprocess)
This output signal is given by a String name, and a String type. Creates a signal declaration by a method STree_mkSignalDeclaration(), and adds it to the process's interface by STree_addDeclarationToInterface().
name
- a String name of the output signaltype
- a String type name of the output signalvprocess
- a Signal process where this output signal is to be added intopublic java.lang.String Generate_Signal_comment(java.lang.String signal_name)
signal_name
- a string of signal namepublic void ASME2SSME_component_instance(ProcessModelImpl vprocess, ProcessModelImpl pprocess, java.lang.String label)
For each formal declaration (parameter,input,output) of vprocess, create a local signal (vprocess_input) as an effective parameter of the call.
vprocess
- a Signal process that represents an upper level component that contains the component of vprocesspprocess
- a Signal process that represents an AADL (sub) componentlabel
- a String labelpublic void ASME2SSME_add_Declaration_to_ProcessType_Interface(java.lang.String name, java.lang.String type, ProcessModelImpl vprocess, SignalElementImpl mmodel, int i)
This singal is given by a String name, and a String type. Creates a signal declaration by a method STree_mkSignalDeclaration(). Find out the process type declaration from an upper level Signal process (mmodel) by STree_GetProcessTypeDeclarationFromAProcess(). this ProcessType is named as TT_xx, where xx is the name of a ProcessModel (vprocess). Adds this signal declaration to the process type.
name
- a String name of this signaltype
- a String type name of this signalvprocess
- a Signal process that represents an AADL process implementation componentmmodel
- a Signal process that represents a system implementation componenti
- an integer which 1 for parameter, 2 for input, and 3 for outputpublic void ASME2SSME_add_IDInterface_to_Process(ProcessModelImpl vprocess, java.lang.String id_name)
vprocess
- a Signal process which the interface is to be addedid_name
- a string name of the interface identifierpublic boolean ASME2SSME_Process_Interface_Contain_Signal(ProcessModelImpl vprocess, java.lang.String sig_name)
vprocess
- a Signal processsig_name
- a string name of a signalpublic SignalsDeclarationImpl ASME2SSME_BehavioredImpl_SubprogramSubcomponent1(org.osate.aadl2.SubprogramSubcomponent sub_sp, org.osate.aadl2.BehavioredImplementation t)
sub_sp
- a subprogram subcomponent