webservices/wsframework/inc/seninternalserviceconsumer.h
changeset 0 62f9d29f7211
child 12 20aafbbfb68e
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 SEN_INTERNAL_SERVICE_CONSUMER_H
       
    26 #define SEN_INTERNAL_SERVICE_CONSUMER_H
       
    27 
       
    28 // INCLUDES
       
    29 #include <e32base.h>
       
    30 #include <s32strm.h>
       
    31 
       
    32 #include "senserviceinvocationframework.h"
       
    33 #include "msenremoteserviceconsumer.h"
       
    34 #include "senwsdescription.h"
       
    35 #include <SenServiceConnection.h>
       
    36 
       
    37 // FORWARD DECLARATION
       
    38 //class MSenPolicy;
       
    39 //class CSenPolicy;
       
    40 class CSenServiceSession;
       
    41 class CSenIdentifier;
       
    42 class MSenProperties;
       
    43 
       
    44 // CLASS DECLARATION
       
    45 
       
    46 /**
       
    47 * Base class for internal consumers of various SIF implementations,
       
    48 * offers for example a unique id implementation..
       
    49 */
       
    50 class CSenInternalServiceConsumer : public CSenWSDescription,
       
    51                                     public MSenRemoteServiceConsumer
       
    52     {
       
    53     public: // Constructors and destructor
       
    54         IMPORT_C virtual ~CSenInternalServiceConsumer();
       
    55 
       
    56         // New functions
       
    57     
       
    58         virtual CSenServiceSession* ServiceSession() = 0; 
       
    59         IMPORT_C virtual TBool IsReadyL();
       
    60         IMPORT_C RFileLogger* Log() const;  
       
    61         
       
    62         // Functions from base classes
       
    63     
       
    64         // From MSenRemoteServiceConsumer
       
    65         IMPORT_C virtual const TDesC8& Id() const;
       
    66         IMPORT_C virtual TInt SetSessionL(MSenRemoteServiceSession& aServiceSession);
       
    67 
       
    68         IMPORT_C virtual TInt HandleMessageL(HBufC8* aMessage,
       
    69                                              const TInt aTxnId,
       
    70                                              MSenProperties* aResponseTransportProperties);
       
    71 
       
    72         IMPORT_C virtual TInt HandleErrorL(HBufC8* aError,
       
    73                                            const TInt aErrorCode,
       
    74                                            const TInt aTxnId,
       
    75                                            MSenProperties* aResponseTransportProperties);
       
    76 
       
    77         IMPORT_C virtual void SetStatusL(const TInt aStatus);
       
    78 
       
    79         IMPORT_C CSenIdentifier& CSenInternalServiceConsumer::Identifier() const;
       
    80 
       
    81         IMPORT_C TInt ChunkByTxnIdL(TInt aTxnId, CSenChunk*& aChunk);
       
    82 
       
    83         IMPORT_C virtual void FileProgress(TInt aTxnId, TBool aIncoming, TBool aIsSoap,
       
    84                 const TDesC8& aSoapOrCid, TInt aProgress);    
       
    85         /**
       
    86         * @see CSenWSDescription
       
    87         */
       
    88         IMPORT_C virtual TBool HasSuperClass( TDescriptionClassType aType );
       
    89 		IMPORT_C virtual void SetDataTrafficDetails( TSenDataTrafficDetails& aDetails) ; 		
       
    90 
       
    91     protected:
       
    92         
       
    93         /**
       
    94         * C++ default constructor.
       
    95         */
       
    96         IMPORT_C CSenInternalServiceConsumer(TDescriptionClassType aType,
       
    97         
       
    98         /**
       
    99         * By default Symbian 2nd phase constructor is private.
       
   100         */                                   CSIF& aSIF);
       
   101         IMPORT_C void ConstructL();
       
   102 
       
   103         /**
       
   104         * getter for children
       
   105         */
       
   106         IMPORT_C CSIF& Framework();
       
   107 
       
   108     private: // Data
       
   109         CSIF& iSIF; // Not owned
       
   110         // Owned. Typically an empty policy.
       
   111         //CSenPolicy* iPolicy; // is deprecated, not in use
       
   112         HBufC8* ipConsumerId;
       
   113         CSenIdentifier* ipIdentifier;
       
   114         TSenDataTrafficDetails iDetails;
       
   115     };
       
   116 
       
   117 #endif // SEN_INTERNAL_SERVICE_CONSUMER_H
       
   118 
       
   119 // End of File