|
1 /* |
|
2 * Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef PUSHREGISTRYMESSAGES_H |
|
20 #define PUSHREGISTRYMESSAGES_H |
|
21 |
|
22 #include "comms.h" |
|
23 |
|
24 using namespace java::comms; |
|
25 |
|
26 namespace java |
|
27 { |
|
28 namespace push |
|
29 { |
|
30 |
|
31 //This message retrieves all push connections of the MIDlet. |
|
32 //First argument: |
|
33 //Uid object => UID of the MIDlet. |
|
34 const int IPC_PR_GET_ALL_PUSH_REGS = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 1; |
|
35 |
|
36 //First argument: |
|
37 //Uid object => UID of the MIDlet. |
|
38 //Second argument: |
|
39 //int => status |
|
40 //0 => success case, less than 0 means the error case |
|
41 //Third argument: |
|
42 //string => error text |
|
43 //This is empty string("") in the success case. |
|
44 //0...n arguments: |
|
45 //wstring => push registry URI. |
|
46 //wstring => push registry filter. |
|
47 const int IPC_PR_LIST_OF_ALL_PUSH_REGS = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 2; |
|
48 |
|
49 //First argument: |
|
50 //Uid object => UID of the MIDlet. |
|
51 //Second argument: |
|
52 //wstring => URI |
|
53 //Third argument: |
|
54 //wstring => name of the MIDlet |
|
55 //Fourth argument: |
|
56 //wstring => filter of the dynamic push connection |
|
57 //Fifth argument: |
|
58 //int => this value indicates whether dynamic push conn is registered to the same MIDlet where |
|
59 // PushRegistry.registerConnection() operation was called. |
|
60 // 0 = uid belongs to the other MIDlet in the same MIDlet suite. |
|
61 // 1 = uid belongs to the same MIDlet where registerConnection() operation was called. |
|
62 const int IPC_PR_REGISTER_DYNAMIC_PUSH_CONN = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 3; |
|
63 |
|
64 //First argument: |
|
65 //Uid object => UID of the MIDlet. |
|
66 //Second argument: |
|
67 //int => status |
|
68 //0 => success case, less than 0 means the error case |
|
69 //Third argument: |
|
70 //string => error text |
|
71 //This is empty string("") in the success case. |
|
72 const int IPC_PR_REGISTER_DYNAMIC_PUSH_CONN_REPLY = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 4; |
|
73 |
|
74 //First argument: |
|
75 //Uid object => UID of the MIDlet. |
|
76 //Second argument: |
|
77 //wstring => URI |
|
78 //Third argument: |
|
79 //int => this value indicates whether dynamic push conn is unregistered from the same MIDlet where |
|
80 // PushRegistry.registerConnection() operation was called. |
|
81 // 0 = uid belongs to the other MIDlet in the same MIDlet suite. |
|
82 // 1 = uid belongs to the same MIDlet where registerConnection() operation was called. |
|
83 const int IPC_PR_UNREGISTER_DYNAMIC_PUSH_CONN = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 5; |
|
84 |
|
85 //First argument: |
|
86 //Uid object => UID of the MIDlet. |
|
87 //Second argument: |
|
88 //int => status |
|
89 //0 => success case, less than 0 means the error case |
|
90 //Third argument: |
|
91 //string => error text |
|
92 //This is empty string("") in the success case. |
|
93 const int IPC_PR_UNREGISTER_DYNAMIC_PUSH_CONN_REPLY = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 6; |
|
94 |
|
95 //First argument: |
|
96 //Uid object => UID of the MIDlet suite. |
|
97 //Second argument: |
|
98 //long => alarm time in milliseconds. |
|
99 //Third argument: |
|
100 //wstring => MIDlet's class name |
|
101 //Fourth argument: |
|
102 //int => this value indicates whether alarm is registered to the other MIDlet in the MIDlet suite. |
|
103 // 0 = uid belongs to the other MIDlet in the same MIDlet suite. |
|
104 // 1 = uid belongs to 'this' MIDlet. |
|
105 const int IPC_PR_REGISTER_ALARM = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 7; |
|
106 |
|
107 //First argument: |
|
108 //Uid object => UID of the MIDlet suite. |
|
109 //Second argument: |
|
110 //int => status |
|
111 //0 => success case, less than 0 means the error case |
|
112 //Third argument: |
|
113 //string => error text |
|
114 //This is empty string("") in the success case. |
|
115 //Fourth argument: |
|
116 //long => time Existing wake up time if alarm is in the pending state. |
|
117 // Value of this argument is zero if wake up time is not already pending. |
|
118 const int IPC_PR_REGISTER_ALARM_REPLY = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 8; |
|
119 |
|
120 /** |
|
121 * This message is sent from PushController to PushRegistryPlugin in the situation wherein |
|
122 * all push connections in the listen mode has failed. |
|
123 * Note: This message does not have reply message. |
|
124 * First argument: |
|
125 * Uid object => UID of the MIDlet. |
|
126 */ |
|
127 const int IPC_PR_ALL_CONNS_FAILED = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 9; |
|
128 |
|
129 /** |
|
130 * This message is sent from PushController to PushRegistryPlugin in the following situations: |
|
131 * 1. Message has arrived to the push connection. |
|
132 * 2. Application has started to handle arrived message of the push connection. |
|
133 * First argument: |
|
134 * Uid object => UID of the MIDlet. |
|
135 * Second argument: |
|
136 * wstring => URI of the push connection. |
|
137 * Third argument: |
|
138 * int => this value contains pending status of the push connection. |
|
139 * 0 = Application has started to handle arrived msg of the push connection. |
|
140 * 1 = Msg has arrived to the push connection and application has not handled it yet. |
|
141 */ |
|
142 const int IPC_PR_PENDING_STATUS = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 10; |
|
143 |
|
144 /** |
|
145 * This message retrieves URIs of all MIDlets' push connections in the MIDlet suite. |
|
146 * First argument: |
|
147 * Uid object => UID of the MIDlet suite. |
|
148 * int => this value indicates whether all push connections are returned or |
|
149 * just "pending connections". |
|
150 * 0 = all push connections are returned. |
|
151 * 1 = only push connections which waiting application's handling. |
|
152 */ |
|
153 const int IPC_PR_LIST_CONNECTIONS = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 11; |
|
154 |
|
155 /** |
|
156 * This message is reply message to the IPC_PR_LIST_CONNECTIONS message. |
|
157 * First argument: |
|
158 * Uid object => UID of the MIDlet suite. |
|
159 * Second argument: |
|
160 * int => status |
|
161 * 0 => success case, less than 0 means the error case |
|
162 * Third argument: |
|
163 * string => error text |
|
164 * This is empty string("") in the success case. |
|
165 * 0...n arguments: |
|
166 * wstring => push registry URI. |
|
167 */ |
|
168 const int IPC_PR_LIST_CONNECTIONS_REPLY = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 12; |
|
169 |
|
170 |
|
171 /** |
|
172 * This message retrieves push connection information based on query argument. |
|
173 * First argument: |
|
174 * Uid object => UID of the MIDlet suite. |
|
175 * Second argument: |
|
176 * wstring => URI. |
|
177 * Third argument: |
|
178 * int => query argument. Can be one of defined in EPushInfoQueryParams enum. |
|
179 */ |
|
180 const int IPC_PR_DATA_OF_PUSH_CONN_QUERY = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 13; |
|
181 |
|
182 /** |
|
183 * This message is reply message to the IPC_PR_DATA_OF_PUSH_CONN_QUERY message. |
|
184 * First argument: |
|
185 * Uid object => UID of the MIDlet suite. |
|
186 * Second argument: |
|
187 * int => status |
|
188 * 0 => success case, less than 0 means the error case. |
|
189 * It is interpreted as an error case if data by query condition is not found. |
|
190 * Third argument: |
|
191 * string => error text |
|
192 * This is empty string("") in the success case. |
|
193 * Fourth argument: |
|
194 * wstring => Result of the query. |
|
195 */ |
|
196 const int IPC_PR_DATA_OF_PUSH_CONN_QUERY_REPLY = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 14; |
|
197 |
|
198 /** |
|
199 * This message asks from PushRegistryPlugin whether start of any push URI is equal |
|
200 * with URI passed as part of this comms msg. |
|
201 * First argument: |
|
202 * wstring => Base URI of the push connection. |
|
203 */ |
|
204 const int IPC_PR_PUSH_URI_STARTS_WITH_QUERY = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 15; |
|
205 |
|
206 /** |
|
207 * This is reply message for IPC_PR_PUSH_URI_STARTS_WITH_QUERY comms msg. This returns |
|
208 * information whether base URI matches to start of any push URI. |
|
209 * Note: This message returns suite uid of first push URI wherein match occurred. |
|
210 * First argument: |
|
211 * int => status information. |
|
212 * 0 => success case. Base uri matches to start of push URI. |
|
213 * -1 => if match does not occurred. |
|
214 * Second argument: |
|
215 * Uid object => suite uid of MIDlet which push URI matches to Base URI. |
|
216 * Note: this argument is not set if value of he first argument is -1. |
|
217 */ |
|
218 const int IPC_PR_PUSH_URI_STARTS_WITH_QUERY_REPLY = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 16; |
|
219 |
|
220 /** |
|
221 * This message is sent from runtime to push registry plugin in the situation wherein |
|
222 * push connection, registered/unregstered by other MIDlet, has been managed. |
|
223 * First argument: |
|
224 * wstring => URI of the closed push connection. |
|
225 */ |
|
226 const int IPC_PR_CONN_COMPLETED = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 17; |
|
227 |
|
228 /** |
|
229 * This message is sent from push registry plugin to runtime after push registry plugin |
|
230 * has got IPC_PR_CONN_COMPLETED comms message(= indicates that push connection has been |
|
231 * closed in other runtime process). This message is also sent if timeout has expired |
|
232 * before arriving a IPC_PR_UNREG_COMPLETED comms message. |
|
233 * This message does not have own arguments. |
|
234 */ |
|
235 const int IPC_PR_CONN_MANAGED_BY_OTHER_MIDLET = JAVACAPTAIN_PUSH_REGISTRY_RANGE_START_C + 18; |
|
236 |
|
237 }//end namespace push |
|
238 }//end namespace java |
|
239 |
|
240 #endif // PUSHREGISTRYMESSAGES_H |
|
241 |