partition.tmplt 3.21 KB
Newer Older
1
2
3
4
@@-- The following tags are available in this template:
@@--
@@-- @_Name_@            : Partition name (usually the name of the binary)
@@-- @_Threads_@         : Code generated for the threads
5
6
@@-- @_Thread_Names_@    : Vector Tag: list of thread names
@@-- @_Thread_Has_Param_@ :  |_  true if the thread has a param
7
8
@@-- @_Node_Name_@       : Name of the node containing this partition
@@-- @_Blocks_@          : Code generated for protected functions
9
10
@@-- @_Block_Names@      : Vector Tag: list of block (user functions) names
@@-- @_Block_Languages_@ :   |_ Corresponding implementation language
11
12
@@-- @_Coverage_@        : True if user requested code coverage enable
@@-- @_Package_Name_@    : AADL Package name for the target (e.g. ocarina_porocessors_x86)
13
14
15
@@-- @_CPU_Name_@        : CPU AADL Identifier (e.g. x86_inst)
@@-- @_CPU_Family_@      : CPU Kind (e.g. leon3)
@@-- @_CPU_Instance_@    : AADL component instance (e.g. rtems_posix)
16
17
@@-- @_CPU_Platform_@    : AADL CPU_Platform (e.g. PLATFORM_NATIVE)
@@-- @_CPU_Classifier_@  : AADL CPU Classifier (e.g. ocarina_processors_x86::x86.linux)
18
19
20
21
@@-- @_VP_Name_@         : Virtual processor name on which the partition is bounded
@@-- @_VP_Platform_@     : Virtual processor platform (e.g. PLATFORM_AIR)
@@-- @_VP_Classifier_@   : Virtual processor classifier
@@-- @_Ada_Runtime_@     : Set if CPU_Platform = PLATFORM_GNAT_RUNTIME
22
23
24
25
26
@@-- @_Bound_Functions_@ : List of user functions from Interface view
@@-- @_Thread_Src_Name_@ : Vector tag : connection thread name (source)
@@-- @_Thread_Dst_Name_@ : Vector tag : connection thread name (dest)
@@-- @_Thread_Src_Port_@ : Vector tag : connection port name (source)
@@-- @_Thread_Dst_Port_@ : Vector tag : connection port name (dest)
27
28
29
30
31
@@-- @_In_Port_Names_@        : Vector tag: input ports of the partition
@@-- @_In_Port_Thread_Name_@  :     |_ corresponding thread inside the partition
@@-- @_In_Port_Type_Name_@    :     |_ corresponding parameter type name (optional)
@@-- @_Out_Port_Names_@       : Vector tag: output ports of the partition
@@-- @_Out_Port_Type_Name_@   :     |_ corresponding parameter type name (optional)
32
33
34
@@-- @_Out_Port_Thread_Name_@ :     |_ corresponding thread inside the partition
@@-- @_Part_Out_Port_Name_@   : Vector tag: output ports of the partition (can be several times the same)
@@-- @_Connected_Threads_@    :     |_ Corresponding thread connected to it
35
36
37
38
with Interfaces.C;
with PolyORB_HI_Generated.Deployment;
use  PolyORB_HI_Generated.Deployment;
@@TABLE@@
39
40
41
  @@IF@@ @_Thread_Has_Param_@
    @@SET@@ Need_Types=True
  @@END_IF@@
42
@@END_TABLE@@
43
44
45
@@IF@@ @_Out_Port_Type_Name_@ /= "" @@-- Also check the output ports
  @@SET@@ Need_Types=True
@@END_IF@@
46
47
48
49
50
51
52
53
@@IF@@ @_Need_Types_@
with PolyORB_HI_Generated.Types;
use  PolyORB_HI_Generated.Types;
@@END_IF@@
@@-- Make sure at least someone includes the user Ada packages (for compilation/elaboration)
@@TABLE@@
  @@IF@@ @_Block_Languages_@ = SDL or @_Block_Languages_@ = Ada
with @_CAPITALIZE:Block_Names_@;
54
pragma Unreferenced (@_CAPITALIZE:Block_Names_@);
55
56
57
  @@END_IF@@
@@END_TABLE@@

58
package @_CAPITALIZE:Name_@_TASTE_Interface is
59
60
61
   --  generated from templates/concurrency_view/ada_wrappers_source/partition.tmplt
   @_Blocks'Indent_@
   @_Threads'Indent_@
62
end @_CAPITALIZE:Name_@_TASTE_Interface;