upnp/upnpstack/upnphttptransfer/inc/httpheader.h
changeset 0 f5a58ecadc66
equal deleted inserted replaced
-1:000000000000 0:f5a58ecadc66
       
     1 /** @file
       
     2 * Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). 
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies  this distribution, and is available 
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Represents one header in transferred file
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef C_CHTTPHEADER_H
       
    20 #define C_CHTTPHEADER_H
       
    21 
       
    22 
       
    23 // System include files
       
    24 #include <e32def.h>
       
    25 #include <e32base.h>
       
    26 
       
    27 /**
       
    28  * Class which represents one header in transferred file
       
    29  *
       
    30  * @lib httptransfer.lib
       
    31  * @since S60 v3.2
       
    32  */
       
    33 NONSHARABLE_CLASS ( CHttpHeader ) : public CBase
       
    34     {
       
    35 public:
       
    36     /**
       
    37      * Destructor
       
    38      *
       
    39      * @since S60 v3.2
       
    40      */
       
    41     ~CHttpHeader();
       
    42     
       
    43     /**
       
    44      * Default constructor
       
    45      *
       
    46      * @since S60 v3.2
       
    47      */
       
    48     CHttpHeader();
       
    49     
       
    50     /**
       
    51      * Constructor
       
    52      *
       
    53      * @since S60 v3.2
       
    54      * @param aFieldName Name of the header field
       
    55      * @param aFieldValue Value of the header field
       
    56      */
       
    57     static CHttpHeader* NewL( const TDesC8& aFieldName, 
       
    58                               const TDesC8& aFieldValue );
       
    59     
       
    60     /**
       
    61      * Getter for the name of the field
       
    62      *
       
    63      * @since S60 v3.2
       
    64      * @return Name of the field
       
    65      */
       
    66     const TDesC8& FieldName();
       
    67     
       
    68     /**
       
    69      * Getter for the value of the field
       
    70      *
       
    71      * @since S60 v3.2
       
    72      * @return Value of the field
       
    73      */
       
    74     const TDesC8& FieldValue();
       
    75 
       
    76 private:
       
    77     /**
       
    78      * Second phase constructor
       
    79      *
       
    80      * @since S60 v3.2
       
    81      * @param aFieldName Name of the header field
       
    82      * @param aFieldValue Value of the header field
       
    83      */
       
    84     void ConstructL( const TDesC8& aFieldName, const TDesC8& aFieldValue );
       
    85     
       
    86 private:
       
    87 
       
    88     /**
       
    89      * Header field name
       
    90      * Own.
       
    91      */
       
    92     HBufC8* iFieldName;
       
    93     
       
    94     /**
       
    95      * Value of the field
       
    96      * Own.
       
    97      */
       
    98     HBufC8* iFieldValue;
       
    99     };
       
   100 
       
   101 #endif // C_CHTTPHEADER_H