multimediacommsengine/tsrc/testdriver/siptester/ttcnresolverplugin/src/CTTCNResolverPluginBase.h
changeset 0 1bce908db942
equal deleted inserted replaced
-1:000000000000 0:1bce908db942
       
     1 /*
       
     2 * Copyright (c) 2004 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:  See class definition below.
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef __CTTCNRESOLVERPLUGINBASE_H__
       
    19 #define __CTTCNRESOLVERPLUGINBASE_H__
       
    20 
       
    21 // INCLUDES
       
    22 #include <apgcli.h>
       
    23 #include "SipResolvedClient.h"
       
    24 
       
    25 // CLASS DEFINITION
       
    26 /**
       
    27  * CTTCNResolverPluginBase base class for testing plugins of ClientResolver.
       
    28  */
       
    29 class CTTCNResolverPluginBase : public CSIPResolvedClient
       
    30 	{
       
    31 	public:	// Constructors and destructor
       
    32 
       
    33 		/// Destructor
       
    34 		virtual ~CTTCNResolverPluginBase();
       
    35 
       
    36 	public: // from CSIPResolvedClient
       
    37 	
       
    38 	    TUid ChannelL( RStringF aMethod,
       
    39                        const TDesC8& aRequestUri,
       
    40                        const RPointerArray<CSIPHeaderBase>& aHeaders,
       
    41                        const TDesC8& aContent,
       
    42                        const CSIPContentTypeHeader* aContentType=0);
       
    43 
       
    44 		void ConnectL( TUid aUid );
       
    45 
       
    46 	protected: // Constructors
       
    47 
       
    48 		inline CTTCNResolverPluginBase() {}
       
    49 		
       
    50 		// Second phase constructor
       
    51 		void ConstructL(); 
       
    52 		
       
    53 		HBufC8* ReadFileContentsL( const TFileName& aFileName );
       
    54 		
       
    55 		void ConstructUidFileNameL( const TDesC& aFilePath, 
       
    56                                     TInt aUid, 
       
    57                                     const TDesC& aExtension, 
       
    58                                     TFileName& aFileName );
       
    59 	
       
    60 	protected: // derived class must implement:
       
    61 	
       
    62 	    virtual TInt32 MyUid() const = 0;
       
    63 	
       
    64 	private: // New functions
       
    65 
       
    66 		// Needed for cleanup of a RImplInfoPtrArray:
       
    67 		static void ResetAndDestroy( TAny* anArray );
       
    68 
       
    69 		// Name
       
    70 		RApaLsSession iApaSession;
       
    71 		TApaAppInfo iAppInfo;
       
    72 		
       
    73 		TUid iApplicationUID;
       
    74 	};
       
    75 
       
    76 #endif // __CTTCNRESOLVERPLUGIN_H__