networkprotocolmodules/common/suplrrlpasn1/inc/suplasn1decoder.h
branchGCC_SURGE
changeset 49 5f20f71a57a3
parent 41 ec40843d536a
parent 45 15a2125aa2f3
equal deleted inserted replaced
41:ec40843d536a 49:5f20f71a57a3
     1 // Copyright (c) 2007-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  @file
       
    18  @internalTechnology
       
    19  
       
    20 */
       
    21 #ifndef SUPL_ASN1_DECODER_H
       
    22 #define SUPL_ASN1_DECODER_H
       
    23 
       
    24 #include <e32base.h>
       
    25 
       
    26 // forward declarations
       
    27 class CSuplMessageBase;
       
    28 class CSuplAsn1DecoderImpl;
       
    29 
       
    30 /**
       
    31 The CSuplAsn1Decoder class provides an interface to the SUPL Protocol Module
       
    32 enabling the decoding of ASN1 encoded SUPL messages. Such messages arrive through
       
    33 either via SMS or WAP push protocols in the case of SUPL INIT messages, or via 
       
    34 a TCP/IP connection once a SUPL session has been established.
       
    35 
       
    36 The decoder provides synchronous methods for decoding received messages. Once
       
    37 Decode() has been called passing the input buffer, the buffer may be re-used as
       
    38 the decoded data is fully extracted to objects owned by the CSuplMessageBase
       
    39 derived classes.
       
    40 
       
    41 On completion of the Decode() operation, the appropriate CSuplMessageBase object
       
    42 is constructed, encapsulating the decoded message. Ownership of this object is
       
    43 passed to the calling function.
       
    44 
       
    45 @internalTechnology
       
    46 @see CSuplMessageBase
       
    47 */
       
    48 NONSHARABLE_CLASS(CSuplAsn1Decoder) : public CBase
       
    49 	{
       
    50 public:
       
    51 	IMPORT_C static CSuplAsn1Decoder* NewL();
       
    52 	virtual ~CSuplAsn1Decoder();
       
    53 	
       
    54 public:
       
    55 	IMPORT_C CSuplMessageBase* DecodeL(const TPtrC8* aBuf, TInt& aError);
       
    56 	
       
    57 private:
       
    58 	CSuplAsn1Decoder();
       
    59 	void ConstructL();
       
    60 	
       
    61 	/** Prohibit copy constructor */
       
    62 	CSuplAsn1Decoder(const CSuplAsn1Decoder&);
       
    63 	/** Prohibit assigment operator */
       
    64 	CSuplAsn1Decoder& operator= (const CSuplAsn1Decoder&);
       
    65 
       
    66 private:
       
    67 	/** Handle to the Implementation */
       
    68 	CSuplAsn1DecoderImpl* iImpl;
       
    69 	};
       
    70 
       
    71 #endif // SUPL_ASN1_DECODER_H