williamr@2
|
1 |
// Copyright (c) 1998-2009 Nokia Corporation and/or its subsidiary(-ies).
|
williamr@2
|
2 |
// All rights reserved.
|
williamr@2
|
3 |
// This component and the accompanying materials are made available
|
williamr@4
|
4 |
// under the terms of "Eclipse Public License v1.0"
|
williamr@2
|
5 |
// which accompanies this distribution, and is available
|
williamr@4
|
6 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
williamr@2
|
7 |
//
|
williamr@2
|
8 |
// Initial Contributors:
|
williamr@2
|
9 |
// Nokia Corporation - initial contribution.
|
williamr@2
|
10 |
//
|
williamr@2
|
11 |
// Contributors:
|
williamr@2
|
12 |
//
|
williamr@2
|
13 |
// Description:
|
williamr@2
|
14 |
// Definitions of WBXML message tokens for use in the Wap Parser, WAPP
|
williamr@2
|
15 |
//
|
williamr@2
|
16 |
//
|
williamr@2
|
17 |
|
williamr@2
|
18 |
#if !defined (__WAPPDEF_H__)
|
williamr@2
|
19 |
#define __WAPPDEF_H__
|
williamr@2
|
20 |
|
williamr@2
|
21 |
// ********* GENERAL WBXML TOKENS ***************
|
williamr@2
|
22 |
// WBXML global tokens - applicable to all messages
|
williamr@2
|
23 |
// See WAP Binary XML Content Format, 16-Jun-99, p16.
|
williamr@2
|
24 |
// These and our message specific tokens define our DTD
|
williamr@2
|
25 |
|
williamr@2
|
26 |
// As our DTD is hard coded into the app, we don't use the following -
|
williamr@2
|
27 |
// SWITCH_PAGE - not defined as we only have 1 page
|
williamr@2
|
28 |
// EXT_I_0, EXT_I_1, EXT_I_2
|
williamr@2
|
29 |
// PI - don't define processing inline - all hard coded
|
williamr@2
|
30 |
// LITERAL,LITERAL_C,LITERAL_A,LITERAL_AC - not using literals, don't define elements inline
|
williamr@2
|
31 |
// EXT_T_0,EXT_T_1,EXT_T_2, EXT_0, EXT_1, EXT_2 - not using document extensions
|
williamr@2
|
32 |
// OPAQUE - not using opaque data
|
williamr@2
|
33 |
|
williamr@2
|
34 |
#define KWAPP_STR_TERM 0x00 // Basically the NULL terminator character for a string
|
williamr@2
|
35 |
#define KWAPP_END_TAG 0x01 // Code for the end of an element
|
williamr@2
|
36 |
#define KWAPP_ENTITY 0x02 // indicates the start of a character entity number
|
williamr@2
|
37 |
#define KWAPP_STR_I 0x03 // indicates the start of an inline string,
|
williamr@2
|
38 |
// terminated by '\0', OR STR_TERMINATOR
|
williamr@2
|
39 |
#define KWAPP_STR_T 0X83 // a reference to the string table follows. Token is followed
|
williamr@2
|
40 |
// by multi byte Int32 referencing an offset in the string table
|
williamr@2
|
41 |
|
williamr@2
|
42 |
#define KWAPP_TAG_CONTENT 0x40 // Bit 6 of the Wap Tag is set when a element has content
|
williamr@2
|
43 |
#define KWAPP_TAG_ATTRIBUTES 0x80 // Bit 7 of Tag is set when the element has attributes
|
williamr@2
|
44 |
#define KWAPP_TAG_ATTRIBUTES_CONTENT 0XC0 // Bits 6 & 7 are set - attributes and content
|
williamr@2
|
45 |
#define KWAPP_MB_INT32_CONTINUATION 0x80 // Continuation Bit of an octet of a Multibyte 32 bit int is set.
|
williamr@2
|
46 |
// Binary encoding for remote configuration of WAP browser settings
|
williamr@2
|
47 |
// same as for the Nokia 7110
|
williamr@2
|
48 |
|
williamr@2
|
49 |
// ********** APPLICATION SPECIFIC CODE LEVEL TAG TOKENS *************
|
williamr@2
|
50 |
#define KWAPP_CHAR_LIST 0x05 // Code level tag (CLT), indicates start
|
williamr@2
|
51 |
// of a characteristic list element
|
williamr@2
|
52 |
#define KWAPP_CHARACTERISTIC 0x06 // code level tag (CLT), indicates start
|
williamr@2
|
53 |
// of a characteristic element
|
williamr@2
|
54 |
#define KWAPP_PARM 0x07 // CLT indicating start of a
|
williamr@2
|
55 |
// attribute element of a characteristic
|
williamr@2
|
56 |
|
williamr@2
|
57 |
// *************** ATTRIBUTE TOKENS *****************************
|
williamr@2
|
58 |
#define KWAPP_TYPE 0x05 // Undocumented token which indicates the
|
williamr@2
|
59 |
// start of a TYPE attribute i.e. "TYPE="
|
williamr@2
|
60 |
#define KWAPP_ADDR_TYPE 0x06 // Characteristic type = ADDRESS
|
williamr@2
|
61 |
#define KWAPP_URL_TYPE 0x07 // Characteristic type = URL
|
williamr@2
|
62 |
#define KWAPP_NAME_TYPE 0x08 // Characteristic Type = NAME
|
williamr@2
|
63 |
#define KWAPP_ID 0x7D // Characteristic Type = ID
|
williamr@2
|
64 |
#define KWAPP_BOOKMARK 0x7F // Characteristic Type = BOOKMARK
|
williamr@2
|
65 |
|
williamr@2
|
66 |
#define KWAPP_NAME_ATTRIB 0x10 // A NAME attribute follows, i.e "NAME="
|
williamr@2
|
67 |
#define KWAPP_VALUE_ATTRIB 0x11 // A VALUE attribute follows, i.e "VALUE"
|
williamr@2
|
68 |
|
williamr@2
|
69 |
// *************** PARM TYPES and VALUES ***************************
|
williamr@2
|
70 |
#define KWAPP_BEARER 0x12 // This is a BEARER element
|
williamr@2
|
71 |
#define KWAPP_PROXY 0x13 // This is a PROXY
|
williamr@2
|
72 |
#define KWAPP_PORT 0x14 // PORT element
|
williamr@2
|
73 |
#define KWAPP_NAME 0x15 // This is a NAME element
|
williamr@2
|
74 |
|
williamr@2
|
75 |
// IMPORTANT tag 0x16 had different meanings for different versions of the OTA settings
|
williamr@2
|
76 |
// Not in Ver 4.0, = ICON token in Version 4.3 but 4.3 NOT SUPPORTED!!
|
williamr@2
|
77 |
|
williamr@2
|
78 |
#define KWAPP_PROXYTYPE 0x16 // PROXY_TYPE in Settings specification version 5.0!
|
williamr@2
|
79 |
|
williamr@2
|
80 |
#define KWAPP_URL 0x17 // Not defined for Version 4.0
|
williamr@2
|
81 |
// Start of a URL, i.e. "TYPE=URL" for Version 5.0
|
williamr@2
|
82 |
#define KWAPP_PROXY_AUTHNAME 0x18 // Not defined for Ver. 4.0 - website uses Proxy token and inline string "AUTHNAME"
|
williamr@2
|
83 |
// Version 5.0 - proxy name follows
|
williamr@2
|
84 |
#define KWAPP_PROXY_AUTHSECRET 0x19 // Not defined for Version 4.0 - use Proxy token and inline string
|
williamr@2
|
85 |
// Versions 5.0 - the password for the proxy follows
|
williamr@2
|
86 |
#define KWAPP_SMS_SMSC_ADDR 0x1A // Service centre address for SMS service
|
williamr@2
|
87 |
#define KWAPP_USSD_SERV_CODE 0x1B // Service centre address for USSD service
|
williamr@2
|
88 |
#define KWAPP_ACCESS_POINT_NAME 0x1C // GPRS access point
|
williamr@2
|
89 |
#define KWAPP_PPP_LOGIN_TYPE 0x1D
|
williamr@2
|
90 |
#define KWAPP_PROXY_LOGIN_TYPE 0x1E
|
williamr@2
|
91 |
#define KWAPP_CSD_DIALSTRING 0x21 // Dialing sting for CSD gateway
|
williamr@2
|
92 |
#define KWAPP_PPP_AUTHTYPE 0x22 // type of authentification
|
williamr@2
|
93 |
#define KWAPP_PPP_AUTHNAME 0x23 // authentification name
|
williamr@2
|
94 |
#define KWAPP_PPP_AUTHSECRET 0x24 // authentification password
|
williamr@2
|
95 |
#define KWAPP_PPP_LOGINTYPE 0x25 // authentification password
|
williamr@2
|
96 |
#define KWAPP_CSD_CALLTYPE 0x28 // CSD calltype
|
williamr@2
|
97 |
#define KWAPP_CSD_CALLSPEED 0x29 // CSD callspeed
|
williamr@2
|
98 |
|
williamr@2
|
99 |
#define KWAPP_GSM_SMS_OLD 0x41 // Defined as GSM\SMS in Nokia Spec version 4.0,but not 5.0
|
williamr@2
|
100 |
// Distinguish it's Ver 4.0 by WAP Version ( = 1.0 )
|
williamr@2
|
101 |
// For versions 5.0 the WAP XML version = 1.1, & token = 0x46
|
williamr@2
|
102 |
|
williamr@2
|
103 |
#define KWAPP_GSM_CSD 0x45 // GSM CSD service
|
williamr@2
|
104 |
|
williamr@2
|
105 |
// IMPORTANT tag 0x46 has multiple meaning across different versions of the Over the Air settings
|
williamr@2
|
106 |
#define KWAPP_GSM_SMS_NEW 0x46 // Not defined for Version 4.0
|
williamr@2
|
107 |
// GSM SMS Nokia spec version 5.0
|
williamr@2
|
108 |
|
williamr@2
|
109 |
#define KWAPP_GSM_USSD 0x47 // Unstructured Short Service Data service
|
williamr@2
|
110 |
// Not defined for version 4.0
|
williamr@2
|
111 |
|
williamr@2
|
112 |
//IMPORTANT tag 0x48 has different meanings in different versions of the Over the Air Settings specs
|
williamr@2
|
113 |
#define KWAPP_IS136 0x48 // Not defined for Version 4.0
|
williamr@2
|
114 |
// IS-136/CSD service in Nokia spec version 5.0
|
williamr@2
|
115 |
|
williamr@2
|
116 |
#define KWAPP_GPRS 0x49 // GSM/GPRS service - added in OTA v6.0
|
williamr@2
|
117 |
|
williamr@2
|
118 |
|
williamr@2
|
119 |
#define KWAPP_PORT_9200 0x60 // Port 9200 - non continuous and not secure
|
williamr@2
|
120 |
#define KWAPP_PORT_9201 0x61 // Port 9201 - continuous but not secure
|
williamr@2
|
121 |
#define KWAPP_PORT_9202 0x62 // Indicates port 9202 - secure but non continuous conection
|
williamr@2
|
122 |
#define KWAPP_PORT_9203 0x63 // Indicates port 9203 - secure and continuous
|
williamr@2
|
123 |
#define KWAPP_AUTOMATIC 0x64
|
williamr@2
|
124 |
#define KWAPP_MANUAL 0x65
|
williamr@2
|
125 |
#define KWAPP_SPEED_AUTO 0x6A // Use auto selection of speed
|
williamr@2
|
126 |
#define KWAPP_SPEED_9600 0x6B // Indicates comm speed is 9600
|
williamr@2
|
127 |
#define KWAPP_SPEED_14400 0x6C // Indicates comm speed is 14400
|
williamr@2
|
128 |
#define KWAPP_SPEED_19200 0x6D // Comm speed is 19200
|
williamr@2
|
129 |
#define KWAPP_SPEED_28800 0x6E // Comms speed is 28800
|
williamr@2
|
130 |
#define KWAPP_SPEED_38400 0x6F // Comms speed is 38400
|
williamr@2
|
131 |
#define KWAPP_PAP 0x70 // Interface protocol = PAP
|
williamr@2
|
132 |
#define KWAPP_CHAP 0x71 // Interface protocol = CHAP
|
williamr@2
|
133 |
#define KWAPP_ANALOGUE 0x72 // Analogue connection
|
williamr@2
|
134 |
#define KWAPP_ISDN 0x73 // Digital ISDN connection
|
williamr@2
|
135 |
#define KWAPP_SPEED_43200 0x74 // Communication speed of 42K
|
williamr@2
|
136 |
#define KWAPP_SPEED_56700 0x75 // Comm speed of 56k
|
williamr@2
|
137 |
#define KWAPP_MSISDN_NO 0x76 // Proxy type is MSISDN number (relevant for USSD)
|
williamr@2
|
138 |
#define KWAPP_IPV4 0x77 // Proxy type is an IP address (relevant for USSD)
|
williamr@2
|
139 |
#define KWAPP_MSCHAP 0x78 // Interface protocol = CHAP
|
williamr@2
|
140 |
#define KWAPP_NAME_ISP 0X7E // Start of Internet Service Provider follows
|
williamr@2
|
141 |
#define KWAPP_MMS_URL 0x7C // Address of Multi Media Service Centre -added in OTA v7.0
|
williamr@2
|
142 |
|
williamr@2
|
143 |
|
williamr@2
|
144 |
// Labels for use in array of ParsedFields - application specific not Nokia
|
williamr@2
|
145 |
|
williamr@2
|
146 |
// CHARACTERISTIC DELIMITORS
|
williamr@2
|
147 |
_LIT(KWappCharAddress, "CHAR-ADDRESS"); // Start of an Address Characteristic
|
williamr@2
|
148 |
_LIT(KWappCharName, "CHAR-NAME"); // Start of a Name Characteristic
|
williamr@2
|
149 |
_LIT(KWappCharURL, "CHAR-URL"); // Start of a URL Characteristic
|
williamr@2
|
150 |
_LIT(KWappCharMMSURL, "CHAR-MMSURL"); // Start of a URL Characteristic
|
williamr@2
|
151 |
_LIT(KWappCharBookmark, "CHAR-BOOKMARK");// Start of a Bookmark Characteristic
|
williamr@2
|
152 |
_LIT(KWappCharID, "CHAR-ID"); // Start of an ID characteristic
|
williamr@2
|
153 |
|
williamr@2
|
154 |
_LIT(KWappXMLversion,"VERSIONx10");
|
williamr@2
|
155 |
_LIT(KWappPublicID, "PUBLICID");
|
williamr@2
|
156 |
_LIT(KWappCharacterSet, "CHARSET");
|
williamr@2
|
157 |
|
williamr@2
|
158 |
//XML Document Characteristic Tags
|
williamr@2
|
159 |
_LIT(KWappAddr, "ADDRESS");
|
williamr@2
|
160 |
_LIT(KWappURL, "URL");
|
williamr@2
|
161 |
_LIT(KWappMMSURL, "MMSURL"); // Added in v6.6 of Nokia OTA Spec
|
williamr@2
|
162 |
_LIT(KWappName, "NAME");
|
williamr@2
|
163 |
_LIT(KWappBookmark, "BOOKMARK");
|
williamr@2
|
164 |
_LIT(KWappID, "ID");
|
williamr@2
|
165 |
|
williamr@2
|
166 |
|
williamr@2
|
167 |
// General tags
|
williamr@2
|
168 |
_LIT(KWappBearer, "BEARER");
|
williamr@2
|
169 |
_LIT(KWappProxy, "PROXY");
|
williamr@2
|
170 |
_LIT(KWappPort, "PORT");
|
williamr@2
|
171 |
_LIT(KWappProxyType, "PROXY_TYPE");
|
williamr@2
|
172 |
|
williamr@2
|
173 |
_LIT(KWappProxyAuthName, "PROXY_AUTHNAME");
|
williamr@2
|
174 |
_LIT(KWappProxyAuthSecret, "PROXY_AUTHSECRET");
|
williamr@2
|
175 |
_LIT(KWappProxyLoginType, "PROXY_LOGINTYPE");
|
williamr@2
|
176 |
_LIT(KWappSMSCAddress, "SMS_SMSC_ADDRESS");
|
williamr@2
|
177 |
_LIT(KWappUSSDCode, "USSD_SERVICE_CODE");
|
williamr@2
|
178 |
_LIT(KWappISP, "ISP_NAME");
|
williamr@2
|
179 |
_LIT(KWappAccessPointName, "ACCESS_POINT_NAME");
|
williamr@2
|
180 |
|
williamr@2
|
181 |
_LIT(KWappCsdDial, "CSD_DIALSTRING");
|
williamr@2
|
182 |
_LIT(KWappPPPAuthType, "PPP_AUTHTYPE");
|
williamr@2
|
183 |
_LIT(KWappPPPAuthName, "PPP_AUTHNAME");
|
williamr@2
|
184 |
_LIT(KWappPPPAuthSecret, "PPP_AUTHSECRET");
|
williamr@2
|
185 |
_LIT(KWappPPPLoginType, "PPP_LOGINTYPE");
|
williamr@2
|
186 |
_LIT(KWappCsdCallType, "CSD_CALLTYPE");
|
williamr@2
|
187 |
_LIT(KWappCsdCallSpeed, "CSD_CALLSPEED");
|
williamr@2
|
188 |
|
williamr@2
|
189 |
_LIT(KWappGsmCsd, "GSM/CSD");
|
williamr@2
|
190 |
_LIT(KWappGsmSms, "GSM/SMS");
|
williamr@2
|
191 |
_LIT(KWappGsmUssd, "GSM/USSD");
|
williamr@2
|
192 |
_LIT(KWappIS136Csd, "IS136/CSD");
|
williamr@2
|
193 |
_LIT(KWappGprs, "GPRS"); // Added in OTA v6.0
|
williamr@2
|
194 |
|
williamr@2
|
195 |
_LIT(KWappPort9200, "9200");
|
williamr@2
|
196 |
_LIT(KWappPort9201, "9201");
|
williamr@2
|
197 |
_LIT(KWappPort9202, "9202");
|
williamr@2
|
198 |
_LIT(KWappPort9203, "9203");
|
williamr@2
|
199 |
|
williamr@2
|
200 |
_LIT(KWappSpeedAuto, "AUTO");
|
williamr@2
|
201 |
_LIT(KWappSpeed9600, "9600");
|
williamr@2
|
202 |
_LIT(KWappSpeed14400, "14400");
|
williamr@2
|
203 |
// Additional speeds added in Version 5.0
|
williamr@2
|
204 |
_LIT(KWappSpeed19200, "19200");
|
williamr@2
|
205 |
_LIT(KWappSpeed28800, "28800");
|
williamr@2
|
206 |
_LIT(KWappSpeed38400, "38400");
|
williamr@2
|
207 |
_LIT(KWappSpeed43200, "43200");
|
williamr@2
|
208 |
_LIT(KWappSpeed56700, "57600");
|
williamr@2
|
209 |
|
williamr@2
|
210 |
_LIT(KWappPAP, "PAP");
|
williamr@2
|
211 |
_LIT(KWappCHAP, "CHAP");
|
williamr@2
|
212 |
_LIT(KWappMSCHAP, "MSCHAP");
|
williamr@2
|
213 |
_LIT(KWappAnalogue, "ANALOGUE");
|
williamr@2
|
214 |
_LIT(KWappISDN, "ISDN");
|
williamr@2
|
215 |
|
williamr@2
|
216 |
_LIT(KWappAuthAutomatic, "AUTOMATIC");
|
williamr@2
|
217 |
_LIT(KWappAuthManual, "MANUAL");
|
williamr@2
|
218 |
|
williamr@2
|
219 |
_LIT(KWappMsisdnNo, "MSISDN_NO");
|
williamr@2
|
220 |
_LIT(KWappIpv4, "IPV4");
|
williamr@2
|
221 |
|
williamr@2
|
222 |
|
williamr@2
|
223 |
#endif
|