xmlsrv_plat/cxml_library_api/inc/nw_wbxml_token.h
branchRCL_3
changeset 20 889504eac4fb
equal deleted inserted replaced
19:6bcc0aa4be39 20:889504eac4fb
       
     1 /*
       
     2 * Copyright (c) 2000 - 2001 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 the License "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 /** ----------------------------------------------------------------------- **
       
    20     @package:     NW_WBXML
       
    21 
       
    22     @synopsis:    default
       
    23 
       
    24     @description: Wbxml token definitions
       
    25 
       
    26  ** ----------------------------------------------------------------------- **/
       
    27 
       
    28 #ifndef NW_PARSER_WBXML_TOKEN_H
       
    29 #define NW_PARSER_WBXML_TOKEN_H
       
    30 
       
    31 #include <xml/cxml/cxml_proj.h>
       
    32 #include <xml/cxml/nw_string_string.h>
       
    33 
       
    34 #ifdef __cplusplus
       
    35 extern "C"
       
    36 {
       
    37 #endif /* __cplusplus */
       
    38 
       
    39 
       
    40 /*
       
    41  * WBXML global tokens, section 7
       
    42  */
       
    43 
       
    44 #define NW_WBXML_SWITCH_PAGE            0x00
       
    45 #define NW_WBXML_END                    0x01
       
    46 #define NW_WBXML_ENTITY                 0x02
       
    47 #define NW_WBXML_STR_I                  0x03
       
    48 #define NW_WBXML_LITERAL                0x04
       
    49 
       
    50 #define NW_WBXML_EXT_I_0                0x40
       
    51 #define NW_WBXML_EXT_I_1                0x41
       
    52 #define NW_WBXML_EXT_I_2                0x42
       
    53 #define NW_WBXML_PI                     0x43
       
    54 #define NW_WBXML_LITERAL_C              0x44
       
    55 
       
    56 #define NW_WBXML_EXT_T_0                0x80
       
    57 #define NW_WBXML_EXT_T_1                0x81
       
    58 #define NW_WBXML_EXT_T_2                0x82
       
    59 #define NW_WBXML_STR_T                  0x83
       
    60 #define NW_WBXML_LITERAL_A              0x84
       
    61 
       
    62 #define NW_WBXML_EXT_0                  0xC0
       
    63 #define NW_WBXML_EXT_1                  0xC1
       
    64 #define NW_WBXML_EXT_2                  0xC2
       
    65 #define NW_WBXML_OPAQUE                 0xC3
       
    66 #define NW_WBXML_LITERAL_AC             0xC4
       
    67 
       
    68 
       
    69 /*
       
    70  * WBXML tag tokens, section 5.8
       
    71  */
       
    72 
       
    73 #define NW_WBXML_MASK_TAG_ID            0x3F  /* Masks off a tag's "has attribute"
       
    74                                                * and/or "has content" bit(s) */
       
    75 #define NW_WBXML_FLAGS_ATTRIBUTES       0x80
       
    76 #define NW_WBXML_FLAGS_CONTENT          0x40
       
    77 
       
    78 
       
    79 /* TODO:  these defs belong somewhere else */
       
    80 /* Attribute component type info */
       
    81 
       
    82 #define NW_WBXML_ATTR_COMPONENT_TOKEN   0
       
    83 #define NW_WBXML_ATTR_COMPONENT_STRING  1
       
    84 #define NW_WBXML_ATTR_COMPONENT_EXT     2
       
    85 #define NW_WBXML_ATTR_COMPONENT_ENTITY  3
       
    86 #define NW_WBXML_ATTR_COMPONENT_OPAQUE  4
       
    87 #define NW_WBXML_ATTR_COMPONENT_INVALID 5
       
    88 
       
    89 #ifdef __cplusplus
       
    90 } /* extern "C" { */
       
    91 #endif /* __cplusplus */
       
    92 
       
    93 #endif
       
    94 
       
    95