applayerprotocols/httptransportfw/Test/Acceptance/CHttpTestChunkedBase.h
changeset 0 b16258d2340f
equal deleted inserted replaced
-1:000000000000 0:b16258d2340f
       
     1 // Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 
       
    17 #ifndef __CHTTPTESTCHUNKEDBASE__
       
    18 #define __CHTTPTESTCHUNKEDBASE__
       
    19 
       
    20 #include "HttpTestCore.h"
       
    21 #include "CHttpAccepTtestBase.h"
       
    22 #include <http.h>
       
    23 #include <http/mhttpauthenticationcallback.h>
       
    24 
       
    25 #include "csrvaddrval.h"
       
    26 
       
    27 /*	post content which requires authorisation
       
    28 	and provide valid username/password (scooby/doo) */
       
    29 
       
    30 class CHttpTestChunkedBase: public CHttpAcceptTestBase , public MHTTPAuthenticationCallback
       
    31 	{
       
    32 public:
       
    33 	TBool GetNextDataPart(TPtrC8& aDataChunk);
       
    34 	void ReleaseData();
       
    35 	virtual TBool GetCredentialsL(const TUriC8& aURI, RString aRealm, RStringF aAuthenticationType, RString& aUsername,RString& aPassword);
       
    36 
       
    37 protected:
       
    38 	void OpenTestSessionL();
       
    39 	void CloseTestSession();
       
    40 
       
    41 protected:
       
    42 	TBool iUseChunkedTransferEncoding;
       
    43 	TInt iReqBodyChunkCount;
       
    44 	TBool iLastChunk;
       
    45 	/** This has the instance of the settings.ini file.  This instance is passed
       
    46 	 to ReplaceHostNameL() function which uses this instance to retrieve the
       
    47 	 data from settings.ini file.
       
    48 	 */
       
    49 	CScriptFile* iIniSettingsFile;
       
    50 	};
       
    51 
       
    52 #endif