applayerpluginsandutils/httpprotocolplugins/wspinc/MWspHeaderCodePages.h
changeset 0 b16258d2340f
equal deleted inserted replaced
-1:000000000000 0:b16258d2340f
       
     1 // Copyright (c) 2001-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 MWspHeaderCodePages.h
       
    18  @warning : This file contains Rose Model ID comments - please do not delete
       
    19 */
       
    20 
       
    21 #ifndef __MWSPHEADERCODEPAGES_H__
       
    22 #define __MWSPHEADERCODEPAGES_H__
       
    23 
       
    24 // System includes
       
    25 #include <e32base.h>
       
    26 #include <wsp/wsptypes.h>
       
    27 
       
    28 class MWspHeaderCodePages
       
    29 /**
       
    30 @class MWspHeaderCodePages
       
    31 @since			7.0
       
    32 The MWspHeaderCodePages API provides an interface to a set of header code
       
    33 pages as defined by the WSP Specification, July 2001. This capability 
       
    34 associates a page number with a page name. The Server can negotiate the
       
    35 use of header code page proposed by the Client by including the page codes
       
    36 (without the page name) in the return negotiation.
       
    37 
       
    38 The interface allows the set of header code pages to be accessed one by one.
       
    39 The read function provides the caller with a copy of the header code page 
       
    40 information. The set can be reset to the default value of the capability (as
       
    41 defined by the WSP Specification), which is an empty set. A header code page 
       
    42 can be added to the set.
       
    43 @publishedAll
       
    44 @deprecated
       
    45 */
       
    46 	{
       
    47 public:	// Methods
       
    48 
       
    49 /**
       
    50 	@fn				Start() const =0
       
    51 	Intended Usage	:	Ensures that the first header code page in the set is 
       
    52 						available for reading.
       
    53 	@since			7.0
       
    54 	@return			An error code. If there are no header code pages, then the 
       
    55 					value returned is KErrNotFound. If there are header code 
       
    56 					pages then the value KErrNone is returned.
       
    57 	@post			The subsequent call to GetNext() is applied to the first
       
    58 					header code page in the set.
       
    59  */
       
    60 	virtual TInt Start() const =0;
       
    61 
       
    62 /**
       
    63 	@fn				GetNext(TUint8& aPageCode, TPtrC8& aPageName) const =0
       
    64 	Intended Usage	:	Gets the next header code page in the set. If there are 
       
    65 						no code pages left then KErrNotFound error code is 
       
    66 						returned.
       
    67 	@since			7.0
       
    68 	@param			aPageCode	A output parameter reference for a byte with the
       
    69 								extension code page number.
       
    70 	@param			aPageName	A output parameter reference for a buffer with 
       
    71 								the name of the header code page.
       
    72 	@return			An error code. If there are no header code pages left, then 
       
    73 					the value returned is KErrNotFound. If there are header code
       
    74 					pages left then the value KErrNone is returned.
       
    75 	@post			The next header code page in the set is available for reading.
       
    76  */
       
    77 	virtual TInt GetNext(TUint8& aPageCode, TPtrC8& aPageName) const =0;
       
    78 
       
    79 /**
       
    80 	@fn				Reset() =0
       
    81 	Intended Usage	:	Resets the capability to the default. The default is 
       
    82 						defined in the WSP Specification, July 2001, as being an
       
    83 						empty set of code pages.
       
    84 	@since			7.0
       
    85 	@post			The set of header code pages is empty.
       
    86  */
       
    87 	virtual void Reset() =0;
       
    88 
       
    89 /**
       
    90 	@fn				AddHeaderCodePageL(TUint8 aPageCode, const TDesC8& aPageName) =0
       
    91 	Intended Usage	:	Adds a header code page to the set.
       
    92 	@since			7.0
       
    93 	@leave			Leave code KErrNoMemory if the code page cannot be added to 
       
    94 					the set.
       
    95 	@param			aPageCode	A byte with the extension code page number.
       
    96 	@param			aPageName	A buffer with the name of the header code page.
       
    97 	@post			If no error has occured then the header code page has been 
       
    98 					added.
       
    99  */
       
   100 	virtual void AddHeaderCodePageL(TUint8 aPageCode, const TDesC8& aPageName) =0;
       
   101 
       
   102 	};
       
   103 
       
   104 #endif	// __MWSPHEADERCODEPAGES_H__