webservices/idwsfplugin/inc/idwsfdsqueryresponse.h
changeset 0 62f9d29f7211
equal deleted inserted replaced
-1:000000000000 0:62f9d29f7211
       
     1 /*
       
     2 * Copyright (c) 2002-2005 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: Header declaration
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 
       
    21 
       
    22 
       
    23 
       
    24 
       
    25 #ifndef IDWSF_DS_QUERY_RESPONSE_H
       
    26 #define IDWSF_DS_QUERY_RESPONSE_H
       
    27 
       
    28 // INCLUDES
       
    29 #include <SenBaseFragment.h>
       
    30 
       
    31 #include "idwsfresourceoffering.h"
       
    32 #include "idwsfdiscoveryserviceclient.h" // Only constants needed
       
    33 
       
    34 // CONSTANTS
       
    35 const TInt KStateParsingResourceOffering    = 11;
       
    36 const TInt KStateParsingEncryptedResourceId = 111;
       
    37 
       
    38 _LIT8(KQueryResponseXmlns, "urn:liberty:disco:2003-08");
       
    39 _LIT8(KQueryResponseName, "QueryResponse");
       
    40 _LIT8(KQueryResponseQName, "ds:QueryResponse");
       
    41 _LIT8(KStatusName, "Status");
       
    42 _LIT8(KStatusCodeName, "code");
       
    43 
       
    44 // CLASS DECLARATIONS
       
    45 class CIdWsfDsQueryResponse :  public CSenBaseFragment
       
    46     {
       
    47     public: // Constructors and destructor
       
    48         
       
    49         static CIdWsfDsQueryResponse* NewL();
       
    50         static CIdWsfDsQueryResponse* NewLC();
       
    51         static CIdWsfDsQueryResponse* NewL(const TDesC8& aNsUri,
       
    52                                            const TDesC8& aLocalName,
       
    53                                            const TDesC8& aQName);
       
    54         static CIdWsfDsQueryResponse* NewLC(const TDesC8& aNsUri,
       
    55                                             const TDesC8& aLocalName,
       
    56                                             const TDesC8& aQName);
       
    57         virtual ~CIdWsfDsQueryResponse();
       
    58 
       
    59         // New functions
       
    60     
       
    61         /**
       
    62         * Ownership of array elements is retained.
       
    63         */
       
    64         virtual void GetAllServicesL(RPointerArray<CIdWsfServiceInstance>& aDest);
       
    65         virtual TBool IsOk();
       
    66         virtual TPtrC8 ResourceId();
       
    67         virtual RPointerArray<CIdWsfResourceOffering>& ResourceOfferingsL();
       
    68 
       
    69     protected:
       
    70         
       
    71         /**
       
    72         * C++ default constructor.
       
    73         */
       
    74         CIdWsfDsQueryResponse();
       
    75         
       
    76         /**
       
    77         * By default Symbian 2nd phase constructor is private.
       
    78         */
       
    79         void BaseConstructL();
       
    80         void BaseConstructL(const TDesC8& aNsUri,
       
    81                             const TDesC8& aLocalName,
       
    82                             const TDesC8& aQName);
       
    83         
       
    84         // Functions from base classes
       
    85         
       
    86         // From CSenBaseFragment
       
    87         virtual void StartElementL(const TDesC8& aNsUri,
       
    88                                    const TDesC8& aLocalName,
       
    89                                    const TDesC8& aQName,
       
    90                                    const RAttributeArray& aAttributes);
       
    91     
       
    92         virtual void EndElementL(const TDesC8& aNsUri,
       
    93                                  const TDesC8& aLocalName,
       
    94                                  const TDesC8& aQName);
       
    95 
       
    96     protected: // Data
       
    97         HBufC8* ipStatus;  // Owned
       
    98 
       
    99     private: // Data
       
   100         CIdWsfResourceOffering* ipResourceOffering;               // Owned
       
   101         RPointerArray<CIdWsfResourceOffering> iResourceOfferings; // Elements owned
       
   102         CSenCredential* ipCredential;                             // Owned
       
   103         CIdWsfServiceInstance* ipServiceInstance;                 // Owned
       
   104         TTime iNotOnOrAfter;
       
   105     };
       
   106 
       
   107 #endif // IDWSF_DS_QUERY_RESPONSE_H
       
   108 
       
   109 // End of File