natfw/natfwunsaf_protocols/unsaf_codec/inc/natfwunsafrequestedipattribute.h
changeset 0 1bce908db942
equal deleted inserted replaced
-1:000000000000 0:1bce908db942
       
     1 /*
       
     2 * Copyright (c) 2006-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:   
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 
       
    21 #ifndef CNATFWUNSAFREQUESTEDIPATTRIBUTE_H
       
    22 #define CNATFWUNSAFREQUESTEDIPATTRIBUTE_H
       
    23 
       
    24 #include "natfwunsafaddressattribute.h"
       
    25 
       
    26 /**
       
    27  * Class for REQUESTED-IP attribute.
       
    28  *
       
    29  *  @lib natfwunsafprotocols.lib
       
    30  *  @since S60 3.2
       
    31  */
       
    32 class CNATFWUNSAFRequestedIpAttribute : public CNATFWUNSAFAddressAttribute
       
    33     {
       
    34 public: // Constructors and destructor
       
    35 
       
    36     /**
       
    37     * Decodes a UNSAF attribute from a byte stream.
       
    38     * This version is for lookup table.
       
    39     * @param aByteStream Byte stream, containing attribute type,length and
       
    40     *    value.
       
    41     * @return Decoded UNSAF attribute, ownership is transferred.
       
    42     */
       
    43     static CNATFWUNSAFAttribute* DecodeAttributeL(
       
    44         const TDesC8& aByteStream);
       
    45 
       
    46     /**
       
    47     * Creates a new instance of CNATFWUNSAFRequestedIpAttribute
       
    48     * @param aAddress the address
       
    49     * @return A new instance of CNATFWUNSAFRequestedIpAttribute
       
    50     *          ownership is transferred.
       
    51     */
       
    52     IMPORT_C static CNATFWUNSAFRequestedIpAttribute* NewL(
       
    53         const TInetAddr& aAddress);
       
    54 
       
    55     /**
       
    56     * Creates a new instance of CNATFWUNSAFRequestedIpAttribute and
       
    57     * pushes it to the CleanupStack.
       
    58     * @param aAddress the address
       
    59     * @return A new instance of CNATFWUNSAFRequestedIpAttribute,
       
    60     *          ownership is transferred.
       
    61     */
       
    62     IMPORT_C static CNATFWUNSAFRequestedIpAttribute* NewLC(
       
    63         const TInetAddr& aAddress);
       
    64 
       
    65     /**
       
    66     * Destructor, deletes the resources of
       
    67     * CNATFWUNSAFRequestedIpAttribute.
       
    68     */
       
    69     ~CNATFWUNSAFRequestedIpAttribute();
       
    70 
       
    71 public: // From CNATFWUNSAFAttribute
       
    72 
       
    73     CNATFWUNSAFAttribute::TType Type() const;
       
    74 
       
    75 private: // Constructors
       
    76 
       
    77     CNATFWUNSAFRequestedIpAttribute(const TInetAddr& aAddress);
       
    78     };
       
    79 
       
    80 #endif // CNATFWUNSAFREQUESTEDIPATTRIBUTE_H
       
    81 
       
    82