DBA Data[Home] [Help]

PACKAGE: APPS.FND_CP_GSM_IPC

Source


1 PACKAGE  fnd_cp_gsm_ipc AS
2 /* $Header: AFCPSMIS.pls 120.2 2005/08/19 14:39:43 susghosh ship $ */
3 
4 
5 --=========================================================================--
6 /* ICM Functions */
7 --=========================================================================--
8 
9 /*--------------------------------------------------------------------------
10 procedure Unsubscribe -unsub from AQ.  Null -> unsub all
11 -----------------------------------------------------------------------------*/
12 
13 procedure Unsubscribe(cpid in number default null);
14 
15 
16 --=========================================================================--
17 /* Cartridge Functions */
18 --=========================================================================--
19 
20 /*--------------------------------------------------------------------------
21 procedure Init_Cartridge
22 -----------------------------------------------------------------------------*/
23 
24 procedure Init_Cartridge;
25 
26 /*--------------------------------------------------------------------------
27 procedure Shutdown_Cartridge
28 -----------------------------------------------------------------------------*/
29 
30 procedure Shutdown_Cartridge;
31 
32 /*--------------------------------------------------------------------------
33 procedure Cartridge_Init_Service
34 -----------------------------------------------------------------------------*/
35 
36 procedure Cartridge_Init_Service(cpid in Number,
37                         Params in Varchar2,
38                         Debug_Level in Varchar2);
39 
40 /*--------------------------------------------------------------------------
41         Procedure Send_Message:
42 
43         Handle = CPID
44         Message -> Stop, Suspend, Resume, Verify, Initialize
45         Parameters - Currently only used to send parameters with Verify
46         Debug_Level = One character Debug Level
47 -----------------------------------------------------------------------------*/
48 
49 
50 Procedure Send_Message (Handle in Number,
51                         Message in Varchar2,
52                         Parameters in Varchar2,
53                         Debug_Level in Varchar2);
54 
55 /*--------------------------------------------------------------------------
56 Function Get_Status:
57 
58 Reads off of -CPID,  Consumes/Ignores All but last message on AQ
59 Leaves last message on AQ.
60         Handle = CPID
61 -----------------------------------------------------------------------------*/
62 
63 Function Get_Status (Handle in Number) Return Varchar2;
64 
65 --=========================================================================--
66 /* Routines called Externally */
67 --=========================================================================--
68 
69 
70 /*--------------------------------------------------------------------------
71         Procedure Send_Custom_Message:
72 
73         Handle = CPID
74         Type - 8 characters for identifying format
75         Message - Currently only used to send parameters with Verify
76 -----------------------------------------------------------------------------*/
77 
78 
79 Procedure Send_Custom_Message (Handle in Number,
80                         Type in varchar2,
81                         Mesg in Varchar2);
82 
83 
84 --=========================================================================--
85 /* Routines called by Service */
86 --=========================================================================--
87 
88 /*--------------------------------------------------------------------------
89         Procedure Init_Service:
90 
91         Init_Service:
92         Handle = CPID
93         Parameters = Initial Parameter String
94         Debug_Level = One character Debug Level
95 -----------------------------------------------------------------------------*/
96 
97 Procedure Init_Service (Handle in Number,
98                         Parameters out NOCOPY Varchar2,
99                         Debug_Level out NOCOPY Varchar2);
100 
101 
102 /*--------------------------------------------------------------------------
103         Procedure Get_Message:
104 
105         Handle = CPID
106         Message -> Stop, Suspend, Resume, Verify, Custom:<type>, Initialize (Internal)
107         Parameters - used to send parameters with Verify as well as Custom messages.
108         Debug_Level - One character Debug Level - Not valid with Custom Messages
109         Blocking_Flag = Y/N do we wait?
110         Consume_Flag = Y/N do we consume message?
111         More_Flag = Y/N more messages on AQ?
112         Message_Wait_Timeout = Timeout to use when waiting on AQ for msg.
113                 Used for both blocking and non blocking calls. Null= nowait
114         Blocking_Sleep_Time = Only meaningful if blocking_flag = 'Y'.  How
115                 many secs to sleep between looking for messages.
116 
117     Notes:
118         All messages types (returned in parameter Message) can be matched to the functions
119 	MSG_Stop, MSG_Suspend, MSG_Resume, MSG_Verify, and MSG_Custom.  However in the case
120 	of Custom, the returned value will be Custom:<type> where type is an 8 character or
121 	less tag of the developers choice. (for example Custom:INV_ALERT), so only the first
122 	6 charactes of the parameter Message should be compared to MSG_Custom, or else the
123 	tag should be appended to MSG_Custom before comparison.  For example:
124 
125 		if (Message = MSG_Custom || ':' || 'INV_ALERT') then ....
126 
127 	An additional concern regarding the Custom message, is that the Debug_Level is
128 	always null...the service should not interpret this as a command to change the
129 	Debug level to the value Null.
130 
131 
132 -----------------------------------------------------------------------------*/
133 
134 Procedure Get_Message ( Handle in Number,
135                         Message out NOCOPY Varchar2,
136                         Parameters out NOCOPY Varchar2,
137                         Debug_Level out NOCOPY Varchar2,
138                         Blocking_Flag in Varchar2,
139                         Consume_Flag in Varchar2,
140                         Success_Flag out NOCOPY Varchar2,
141                         More_Flag out NOCOPY Varchar2,
142                         Message_Wait_Timeout in number default Null,
143                         Blocking_Sleep_Time in number default 30);
144 
145 
146 /* Messages */
147 
148 Function MSG_Stop return varchar2;
149 Function MSG_Suspend return varchar2;
150 Function MSG_Resume return varchar2;
151 Function MSG_Verify return varchar2;
152 Function MSG_Custom return varchar2;
153 
154 /*--------------------------------------------------------------------------
155         Procedure Update_Status:
156 
157         Handle = CPID
158         Status is one of: Running, Stopped, Suspended,
159                                         Uninitialized (for FND Use only)
160 -----------------------------------------------------------------------------*/
161 
162 
163 Procedure Update_Status ( Handle in Number, Status in Varchar2);
164 
165 /*--------------------------------------------------------------------------
166         Procedure Update_Status_and_info:
167 
168         Handle = CPID
169         Status is one of: Running, Stopped, Suspended,
170                                         Uninitialized (for FND Use only)
171 	Info is varchar2(2000) for service developers use.
172 -----------------------------------------------------------------------------*/
173 
174 
175 Procedure Update_Status_and_Info ( Handle in Number, Status in Varchar2, Info in Varchar2);
176 
177 /* Statuses */
178 
179 Function Status_Running return varchar2;
180 Function Status_Stopped return varchar2;
181 Function Status_Suspended return varchar2;
182 
183 END fnd_cp_gsm_ipc;