webservices/idwsfplugin/inc/idwsfcoreserviceconsumer.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_CORE_SERVICE_CONSUMER_H
       
    26 #define IDWSF_CORE_SERVICE_CONSUMER_H
       
    27 
       
    28 // INCLUDERS
       
    29 #include <MSenServiceDescription.h>
       
    30 
       
    31 #include "seninternalserviceconsumer.h"
       
    32 
       
    33 // FORWARD DECLARATIONS
       
    34 class CIdWsfServiceSession;
       
    35 class MIdWsfSessionValidator;
       
    36 class MSenRemoteHostlet;
       
    37 
       
    38 // CLASS DECLARATION
       
    39 class CIdWsfCoreServiceConsumer : public CSenInternalServiceConsumer
       
    40     {
       
    41     public: // Constructors and destructor
       
    42     
       
    43         static CIdWsfCoreServiceConsumer* NewL(CSIF& aSIF);
       
    44         static CIdWsfCoreServiceConsumer* NewLC(CSIF& aSIF);
       
    45         
       
    46         virtual ~CIdWsfCoreServiceConsumer();
       
    47 
       
    48         // New functions
       
    49     
       
    50         virtual TPtrC8 TrustAnchor() const;
       
    51         virtual TPtrC8 ProviderId() const;
       
    52         virtual void SetServiceSessionL(CIdWsfServiceSession* aSession);
       
    53         virtual const TTime& ValidUntilL();
       
    54 
       
    55         // Functions from base classes
       
    56 
       
    57         // From MSenRemoteServiceSession
       
    58         virtual TInt SetSessionL(MSenRemoteServiceSession& aSession);
       
    59         virtual void StartTransaction();
       
    60         virtual void TransactionCompleted();
       
    61 
       
    62         // From ServiceDescription
       
    63         virtual void SetContractL(const TDesC8& aContract);
       
    64         virtual void SetEndPointL(const TDesC8& aEndpoint);
       
    65         virtual TPtrC8 Contract();
       
    66         virtual TPtrC8 Endpoint();
       
    67         virtual TPtrC8 FrameworkId();
       
    68         virtual TPtrC8 FrameworkVersion();
       
    69         virtual TInt HasFacetL(const TDesC8& aURI, TBool& aHasFacet);
       
    70         virtual TInt FacetValue(TDesC8& aURI, HBufC8*& aValueTo);
       
    71         virtual TInt AddFacetL(const CSenFacet& aFacet);
       
    72         virtual TInt SetFacetL(const CSenFacet& aFacet);
       
    73         virtual TInt RemoveFacet(const TDesC8& aURI);
       
    74         virtual TInt FacetsL(RFacetArray& aFacetArray);
       
    75         virtual TInt ScoreMatchL(MSenServiceDescription& aPattern);
       
    76         virtual TBool Matches(MSenServiceDescription& aPattern);
       
    77         virtual void WriteAsXMLToL(RWriteStream& aWriteStream);
       
    78         virtual CSenServiceSession* ServiceSession();
       
    79 
       
    80         // for framework's internal use
       
    81         
       
    82         virtual CIdWsfServiceSession* IdWsfServiceSession();
       
    83         virtual void SetValidator(MIdWsfSessionValidator* aValidator);
       
    84         virtual MIdWsfSessionValidator* Validator();
       
    85         virtual MSenTransport& TransportL();
       
    86         virtual MSenRemoteServiceConsumer* ServedConsumer();
       
    87         virtual TInt ChunkByTxnIdL(TInt aTxnId, CSenChunk*& aChunk);
       
    88         virtual TBool HasSuperClass( TDescriptionClassType aType );
       
    89 
       
    90         virtual MSenRemoteHostlet* Hostlet() const;
       
    91 
       
    92     protected:
       
    93         
       
    94         /**
       
    95         * C++ default constructor.
       
    96         */
       
    97         CIdWsfCoreServiceConsumer(CSIF& aSIF, TDescriptionClassType aType);
       
    98         
       
    99         /**
       
   100         * By default Symbian 2nd phase constructor is private.
       
   101         */
       
   102         void BaseConstructL();
       
   103 
       
   104     protected: // Data
       
   105         CIdWsfServiceSession* iService; // not owned
       
   106         MSenRemoteServiceConsumer* iServedConsumer; // not owned
       
   107     };
       
   108     
       
   109 #endif // IDWSF_CORE_SERVICE_CONSUMER_H
       
   110 
       
   111 // End of File