Exemplo n.º 1
0
            WS_XML_STRING unsignedIntTypeName;  // unsignedInt
            WS_XML_STRING unsignedLongTypeName;  // unsignedLong
            WS_XML_STRING unsignedShortTypeName;  // unsignedShort
            WS_XML_STRING CharTypeName;  // char
            WS_XML_STRING durationTypeName;  // duration
            WS_XML_STRING guidTypeName;  // guid
        } xmlStrings; // end of XML string list
        WS_XML_DICTIONARY dict;  
    } dictionary;  // end of XML dictionary
} _schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions;

const static _schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions =
{
    {    // dictionary 
        { // xmlStrings
            WS_XML_STRING_DICTIONARY_VALUE("FactoryType",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 0),
            WS_XML_STRING_DICTIONARY_VALUE("http://schemas.microsoft.com/2003/10/Serialization/",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 1),
            WS_XML_STRING_DICTIONARY_VALUE("Id",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 2),
            WS_XML_STRING_DICTIONARY_VALUE("Ref",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 3),
            WS_XML_STRING_DICTIONARY_VALUE("anyType",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 4),
            WS_XML_STRING_DICTIONARY_VALUE("anyURI",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 5),
            WS_XML_STRING_DICTIONARY_VALUE("base64Binary",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 6),
            WS_XML_STRING_DICTIONARY_VALUE("boolean",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 7),
            WS_XML_STRING_DICTIONARY_VALUE("byte",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 8),
            WS_XML_STRING_DICTIONARY_VALUE("dateTime",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 9),
            WS_XML_STRING_DICTIONARY_VALUE("decimal",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 10),
            WS_XML_STRING_DICTIONARY_VALUE("double",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 11),
            WS_XML_STRING_DICTIONARY_VALUE("float",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 12),
            WS_XML_STRING_DICTIONARY_VALUE("int",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 13),
            WS_XML_STRING_DICTIONARY_VALUE("long",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 14),
            WS_XML_STRING_DICTIONARY_VALUE("QName",&schemas_microsoft_com_2003_10_Serialization_xsdLocalDefinitions.dictionary.dict, 15),
         WsOffsetOf(ArrayOfEntityPath, EntityPath),
         WS_FIELD_POINTER| WS_FIELD_NILLABLE_ITEM,
         0,
         WsOffsetOf(ArrayOfEntityPath, EntityPathCount),
         (WS_XML_STRING*)&WalkTheMazeWeb_Models_xsdLocalDefinitions.dictionary.xmlStrings.EntityPathTypeName, // EntityPath
         (WS_XML_STRING*)&WalkTheMazeWeb_Models_xsdLocalDefinitions.dictionary.xmlStrings.ArrayOfEntityPathTypeNamespace, // http://schemas.datacontract.org/2004/07/WalkTheMazeWeb.Models
         0,
         },    // end of field description for EntityPath
         {  // fields description for ArrayOfEntityPath
         (WS_FIELD_DESCRIPTION*)&WalkTheMazeWeb_Models_xsdLocalDefinitions.globalTypes.ArrayOfEntityPathdescs.EntityPath,
         },
     },    // ArrayOfEntityPath
 }, // end of global types
 {  // dictionary 
     {  // xmlStrings
         WS_XML_STRING_DICTIONARY_VALUE("ArrayOfEntityPath",&WalkTheMazeWeb_Models_xsdLocalDefinitions.dictionary.dict, 0),
         WS_XML_STRING_DICTIONARY_VALUE("http://schemas.datacontract.org/2004/07/WalkTheMazeWeb.Models",&WalkTheMazeWeb_Models_xsdLocalDefinitions.dictionary.dict, 1),
         WS_XML_STRING_DICTIONARY_VALUE("EntityPath",&WalkTheMazeWeb_Models_xsdLocalDefinitions.dictionary.dict, 2),
         WS_XML_STRING_DICTIONARY_VALUE("EntityID",&WalkTheMazeWeb_Models_xsdLocalDefinitions.dictionary.dict, 3),
         WS_XML_STRING_DICTIONARY_VALUE("PathToFile",&WalkTheMazeWeb_Models_xsdLocalDefinitions.dictionary.dict, 4),
         WS_XML_STRING_DICTIONARY_VALUE("WorldID",&WalkTheMazeWeb_Models_xsdLocalDefinitions.dictionary.dict, 5),
     },  // end of xmlStrings
     
     {  // WalkTheMazeWeb_Models_xsddictionary
       // e8536673-9db8-4470-879a-673db548ed96 
     { 0xe8536673, 0x9db8, 0x4470, { 0x87, 0x9a, 0x67,0x3d, 0xb5, 0x48, 0xed, 0x96 } },
     (WS_XML_STRING*)&WalkTheMazeWeb_Models_xsdLocalDefinitions.dictionary.xmlStrings,
     6,
     TRUE,
     },
 },  //  end of dictionary
};

ColorDictionary colorDictionary =
{
    { 
        { /* fd7d93f6-a9ec-40a5-a492-8bb45b1e3a5f */
            0xfd7d93f6,
            0xa9ec,
            0x40a5,
            {0xa4, 0x92, 0x8b, 0xb4, 0x5b, 0x1e, 0x3a, 0x5f}
        },
        &colorDictionary.red,
        4, 
        TRUE
    },
    WS_XML_STRING_DICTIONARY_VALUE("red", &colorDictionary.dictionary, 0),
    WS_XML_STRING_DICTIONARY_VALUE("yellow", &colorDictionary.dictionary, 1),
    WS_XML_STRING_DICTIONARY_VALUE("blue", &colorDictionary.dictionary, 2),
    WS_XML_STRING_DICTIONARY_VALUE("green", &colorDictionary.dictionary, 3),
};


struct ShapeDictionary
{
    WS_XML_DICTIONARY dictionary;
    WS_XML_STRING circle;
    WS_XML_STRING square;
    WS_XML_STRING triangle;
};

ShapeDictionary shapeDictionary =
Exemplo n.º 4
0
    WS_XML_DICTIONARY dictionary;
    WS_XML_STRING quantity;
    WS_XML_STRING productName;
    WS_XML_STRING purchaseOrderType;
    WS_XML_STRING purchaseOrderNamespace;
};

static const PurchaseOrderDictionary purchaseOrderDictionary =
{
    { 
        { 0x89d3da8b, 0xec46, 0x4fe8, { 0x9a, 0xb4, 0x48, 0x62, 0xb2, 0x69, 0x71, 0x8a } },
        (WS_XML_STRING*)&purchaseOrderDictionary.quantity,
        4, 
        TRUE 
    },
    WS_XML_STRING_DICTIONARY_VALUE("quantity", &purchaseOrderDictionary.dictionary, 0),
    WS_XML_STRING_DICTIONARY_VALUE("productName", &purchaseOrderDictionary.dictionary, 1),
    WS_XML_STRING_DICTIONARY_VALUE("PurchaseOrderType", &purchaseOrderDictionary.dictionary, 2),
    WS_XML_STRING_DICTIONARY_VALUE("http://example.com", &purchaseOrderDictionary.dictionary, 3),
};


// Print out rich error info
void PrintError(
    __in HRESULT errorCode, 
    __in_opt WS_ERROR* error)
{
    wprintf(L"Failure: errorCode=0x%lx\n", errorCode);

    if (errorCode == E_INVALIDARG || errorCode == WS_E_INVALID_OPERATION)
    {
         0,
         WsOffsetOf(UserData, numberOfUserTags),
          WS_FIELD_OPTIONAL,
         0,
         0xffffffff
         },    // end of field description for numberOfUserTags
         {  // fields description for UserData
         (WS_FIELD_DESCRIPTION*)&EpicWareWeb_xsdLocalDefinitions.globalTypes.UserDatadescs.firstName,
         (WS_FIELD_DESCRIPTION*)&EpicWareWeb_xsdLocalDefinitions.globalTypes.UserDatadescs.lastName,
         (WS_FIELD_DESCRIPTION*)&EpicWareWeb_xsdLocalDefinitions.globalTypes.UserDatadescs.numberOfUserTags,
         },
     },    // UserData
 }, // end of global types
 {  // dictionary 
     {  // xmlStrings
         WS_XML_STRING_DICTIONARY_VALUE("ArrayOfWord",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 0),
         WS_XML_STRING_DICTIONARY_VALUE("http://schemas.datacontract.org/2004/07/EpicWareWeb",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 1),
         WS_XML_STRING_DICTIONARY_VALUE("Word",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 2),
         WS_XML_STRING_DICTIONARY_VALUE("language",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 3),
         WS_XML_STRING_DICTIONARY_VALUE("text",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 4),
         WS_XML_STRING_DICTIONARY_VALUE("topic",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 5),
         WS_XML_STRING_DICTIONARY_VALUE("UserData",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 6),
         WS_XML_STRING_DICTIONARY_VALUE("firstName",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 7),
         WS_XML_STRING_DICTIONARY_VALUE("lastName",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 8),
         WS_XML_STRING_DICTIONARY_VALUE("numberOfUserTags",&EpicWareWeb_xsdLocalDefinitions.dictionary.dict, 9),
     },  // end of xmlStrings
     
     {  // EpicWareWeb_xsddictionary
       // 2a927002-63b3-4479-98e7-efb4bc9ea785 
     { 0x2a927002, 0x63b3, 0x4479, { 0x98, 0xe7, 0xef,0xb4, 0xbc, 0x9e, 0xa7, 0x85 } },
     (WS_XML_STRING*)&EpicWareWeb_xsdLocalDefinitions.dictionary.xmlStrings,
            WsOffsetOf(ArrayOfint, Int),
            0,
            0,
            WsOffsetOf(ArrayOfint, IntCount),
            (WS_XML_STRING*)&schemas_microsoft_com_2003_10_Serialization_Arrays_xsdLocalDefinitions.dictionary.xmlStrings.ArrayOfintIntLocalName, // int
            (WS_XML_STRING*)&schemas_microsoft_com_2003_10_Serialization_Arrays_xsdLocalDefinitions.dictionary.xmlStrings.ArrayOfintTypeNamespace, // http://schemas.microsoft.com/2003/10/Serialization/Arrays
            0,
            },    // end of field description for Int
            {  // fields description for ArrayOfint
            (WS_FIELD_DESCRIPTION*)&schemas_microsoft_com_2003_10_Serialization_Arrays_xsdLocalDefinitions.globalTypes.ArrayOfintdescs.Int,
            },
        },    // ArrayOfint
    }, // end of global types
    {  // dictionary 
        {  // xmlStrings
            WS_XML_STRING_DICTIONARY_VALUE("ArrayOfint",&schemas_microsoft_com_2003_10_Serialization_Arrays_xsdLocalDefinitions.dictionary.dict, 0),
            WS_XML_STRING_DICTIONARY_VALUE("http://schemas.microsoft.com/2003/10/Serialization/Arrays",&schemas_microsoft_com_2003_10_Serialization_Arrays_xsdLocalDefinitions.dictionary.dict, 1),
            WS_XML_STRING_DICTIONARY_VALUE("int",&schemas_microsoft_com_2003_10_Serialization_Arrays_xsdLocalDefinitions.dictionary.dict, 2),
        },  // end of xmlStrings
        
        {  // schemas_microsoft_com_2003_10_Serialization_Arrays_xsddictionary
          // 2a2965a0-b0d5-4fe3-bed6-e98b82f892f5 
        { 0x2a2965a0, 0xb0d5, 0x4fe3, { 0xbe, 0xd6, 0xe9,0x8b, 0x82, 0xf8, 0x92, 0xf5 } },
        (WS_XML_STRING*)&schemas_microsoft_com_2003_10_Serialization_Arrays_xsdLocalDefinitions.dictionary.xmlStrings,
        3,
        TRUE,
        },
    },  //  end of dictionary
}; //  end of schemas_microsoft_com_2003_10_Serialization_Arrays_xsdLocalDefinitions

const _schemas_microsoft_com_2003_10_Serialization_Arrays_xsd schemas_microsoft_com_2003_10_Serialization_Arrays_xsd =
Exemplo n.º 7
0
         (WS_XML_STRING*)&tempuri_org_xsdLocalDefinitions.dictionary.xmlStrings._LoginTypeNamespace, // http://tempuri.org/
         WS_WSZ_TYPE,
         0,
         WsOffsetOf(_LoginResponse, LoginResult),
          WS_FIELD_OPTIONAL| WS_FIELD_NILLABLE,
         0,
         0xffffffff
         },    // end of field description for LoginResult
         {  // fields description for _LoginResponse
         (WS_FIELD_DESCRIPTION*)&tempuri_org_xsdLocalDefinitions.globalElements._LoginResponsedescs.LoginResult,
         },
     },    // _LoginResponse
 }, // end of global elements
 {  // dictionary 
     {  // xmlStrings
         WS_XML_STRING_DICTIONARY_VALUE("Login",&tempuri_org_xsdLocalDefinitions.dictionary.dict, 0),
         WS_XML_STRING_DICTIONARY_VALUE("http://tempuri.org/",&tempuri_org_xsdLocalDefinitions.dictionary.dict, 1),
         WS_XML_STRING_DICTIONARY_VALUE("nick",&tempuri_org_xsdLocalDefinitions.dictionary.dict, 2),
         WS_XML_STRING_DICTIONARY_VALUE("password",&tempuri_org_xsdLocalDefinitions.dictionary.dict, 3),
         WS_XML_STRING_DICTIONARY_VALUE("LoginResponse",&tempuri_org_xsdLocalDefinitions.dictionary.dict, 4),
         WS_XML_STRING_DICTIONARY_VALUE("LoginResult",&tempuri_org_xsdLocalDefinitions.dictionary.dict, 5),
     },  // end of xmlStrings
     
     {  // tempuri_org_xsddictionary
       // b42c0b4a-79d1-4c7e-9d35-e9796bb6d46d 
     { 0xb42c0b4a, 0x79d1, 0x4c7e, { 0x9d, 0x35, 0xe9,0x79, 0x6b, 0xb6, 0xd4, 0x6d } },
     (WS_XML_STRING*)&tempuri_org_xsdLocalDefinitions.dictionary.xmlStrings,
     6,
     TRUE,
     },
 },  //  end of dictionary