webengine/osswebengine/WebCore/platform/network/symbian/DataConnection.h
author Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Wed, 09 Jun 2010 10:52:50 +0300
branchRCL_3
changeset 42 a1a5d4e727e8
parent 0 dd21522fd290
permissions -rw-r--r--
Revision: 201021 Kit: 2010123

/*
* Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies).
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of the License "Eclipse Public License v1.0"
* which accompanies this distribution, and is available
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
*
* Initial Contributors:
* Nokia Corporation - initial contribution.
*
* Contributors:
*
* Description:  
*
*/

#ifndef __DATACONNECTION_H__
#define __DATACONNECTION_H__

#include <e32base.h>
#include "UrlConnection.h"


class DataConnection : public MUrlConnection
{
public:
    DataConnection(WebCore::ResourceHandle* _handle);
    virtual ~DataConnection();
    virtual int submit();
    virtual void cancel();
    /**
    */
    virtual void download(WebCore::ResourceHandle* handle, const WebCore::ResourceRequest& request, const WebCore::ResourceResponse& response);
    virtual int totalContentSize() { return m_maxSize; }
    static TInt sendResponseCb(TAny* aPtr);

private:
    void submitL();
    void parseUrlLC(HBufC8*& contentType, HBufC8*& encoding, HBufC8*& body);
    void sendResponseL();
private:
    CPeriodic* m_scheduler;
    int m_maxSize;
};

#endif // __DATACONNECTION_H__
// end of file