landmarks/locationlandmarks/converter/inc/epos_cposlmurlparseroperation.h
author Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Tue, 31 Aug 2010 15:37:04 +0300
branchRCL_3
changeset 20 2b4ea9893b66
parent 0 667063e416a2
permissions -rw-r--r--
Revision: 201033 Kit: 201035

/*
* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). 
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of "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: Class for executing the parsing of URL operation
*
*
*/


#ifndef CPOSLMURLPARSEROPERATION_H
#define CPOSLMURLPARSEROPERATION_H

//  INCLUDES
#include "EPos_CPosLmConverterOperation.h"

// CONSTANTS

// FORWARD DECLARATIONS
class CPosLmUrlParser;

// CLASS DECLARATION

/**
* Operation for parsing the URL . This operation can be either synchronous
* or asynchronous.
*
*  @lib eposconverter.lib
*/
class CPosLmUrlParserOperation : public CPosLmConverterOperation
    {

    public:  // Constructors and destructor

        /**
        * Two-phased constructor.
        * @param aEncoderOutput The output for the encoder. This class takes
        *   ownership of the output.
        * @param In: aUrlParser An instance of the URL parser class.
        * @returns A new instance of this class.
        */
        static CPosLmUrlParserOperation* NewL(
        			        CPosLmUrlParser& aUrlParser
        );

        /**
        * Destructor.
        */
        virtual ~CPosLmUrlParserOperation();

    public: // Functions from base classes

        /**
        * From CPosLmConverterOperation;
        *
        * @param out: aProgress Will be set to the progress of the operation when
        * the step has finished.
        * @return KErrNone if the operation has finished successfully.
        */
        TInt NextStepL(
        			   TReal32& aProgress
        );

        /**
        * From CPosLmConverterOperation;
        *
        * @param aError An error code generated by NextStepL.
        */
        void HandleError(
        /* IN/OUT */    TInt& aError
        );
        
        /**
         * Destroys the url parser instance
         */
        void DisconnectUrlParser();

        
    private:

        /**
        * C++ default constructor.
        * @param out: aEncoderOutput The output for the encoder. This class takes
        *   ownership of the output.
        */
        CPosLmUrlParserOperation(
               CPosLmUrlParser& aUrlParser
        );

        /**
        * By default Symbian 2nd phase constructor is private.
        */
        void ConstructL();

        // Prohibit copy constructor 
        CPosLmUrlParserOperation(const CPosLmUrlParserOperation&);
        // Prohibit assigment operator 
        CPosLmUrlParserOperation& operator=(const CPosLmUrlParserOperation&);

    private:    // Data

				// Handle to landmarks URl parser
        CPosLmUrlParser*       iUrlParser;
        // Holds the status of the parser operation
        TInt		           iStatus;

    };

#endif      // CPOSLMURLPARSEROPERATION_H

// End of File