natplugins/natpcliprovisioningnatfwadapter/inc/natfwiapspecificitem.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:  NAT-FW Traversal access point specific settings
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 //  INCLUDES
       
    20 #include <e32base.h>
       
    21 
       
    22 class CWPCharacteristic;
       
    23 
       
    24 /**
       
    25 * Buffer class for accesspoint specific settings in NAT/FW Traversal adapter
       
    26 * @since S60 v3.1
       
    27 */
       
    28 class CNATFWIAPSpecificItem : public CBase
       
    29     {
       
    30     public:
       
    31         
       
    32         static CNATFWIAPSpecificItem* NewL();
       
    33 
       
    34         static CNATFWIAPSpecificItem* NewLC();
       
    35     
       
    36         virtual ~CNATFWIAPSpecificItem();
       
    37 
       
    38     public: // New methods
       
    39     
       
    40         /**
       
    41          * Getter for NAPDEF name (IAP settings name).
       
    42          * @since S60 v3.1
       
    43          * @return NAPDEF name
       
    44          */
       
    45         const TDesC8& NapDefName() const;
       
    46 
       
    47         /**
       
    48          * Getter for NAPDEF (IAP settings).
       
    49          * @since S60 v3.1
       
    50          * @return NAPDEF characteristic.
       
    51          */
       
    52         CWPCharacteristic* NapDef();
       
    53         
       
    54         /**
       
    55          * Setter for NAPDEF name (IAP settings).
       
    56          * @since S60 v3.1
       
    57          * @param aToNapId. To NapId value
       
    58          */
       
    59         void SetNapDefNameL( const TDesC8& aToNapId );
       
    60       
       
    61         /**
       
    62         * Setter for NAPDEF (IAP settings).
       
    63         * @since Series 60 3.0.
       
    64         * @param aNapDef. NAPDEF characteristic.
       
    65         */ 
       
    66         void SetNapDef( CWPCharacteristic* aNapDef );
       
    67         
       
    68         /**
       
    69         * Setter for IAPKey.
       
    70         * @since Series 60_3.1
       
    71         * @param aIAPKey value to set.
       
    72         */
       
    73         void SetIAPKey( TUint32 aIAPKey );
       
    74         
       
    75         /**
       
    76         * Setter for IAPId.
       
    77         * @since Series 60_3.1
       
    78         * @param aIAPId value to set.
       
    79         */
       
    80         void SetIAPId( TUint32 aIAPId );
       
    81          
       
    82         /**
       
    83         * Setter for IntervalUDP.
       
    84         * @since Series 60_3.1
       
    85         * @param aIntervalUDP value to set.
       
    86         */   
       
    87         void SetIntervalUDP( TInt aIntervalUDP );
       
    88 
       
    89         /**
       
    90         * Setter for IntervalTCP.
       
    91         * @since Series 60_3.1
       
    92         * @param aIntervalTCP value to set.
       
    93         */
       
    94         void SetIntervalTCP( TInt aIntervalTCP );
       
    95 
       
    96         /**
       
    97         * Setter for STUNRetransmitTimer.
       
    98         * @since Series 60_3.1
       
    99         * @param aSTUNRetransmitTimer value to set.
       
   100         */
       
   101         void SetSTUNRetransmitTimer( TInt aSTUNRetransmitTimer );
       
   102                          
       
   103         /**
       
   104         * Getter for IAPKey. 
       
   105         * @since Series 60_3.1
       
   106         * @return Key for IAP table in CenRep.
       
   107         */                    
       
   108         TUint32 GetIAPKey() const;
       
   109 
       
   110         /**
       
   111         * Getter for IAPId. 
       
   112         * @since Series 60_3.1
       
   113         * @return IAP ID.
       
   114         */
       
   115         TUint32 GetIAPId() const;
       
   116 
       
   117         /**
       
   118         * Getter for IntervalUDP. 
       
   119         * @since Series 60_3.1
       
   120         * @return IntervalUDP value
       
   121         */
       
   122         TInt GetIntervalUDP() const;
       
   123 
       
   124         /**
       
   125         * Getter for IntervalTCP. 
       
   126         * @since Series 60_3.1
       
   127         * @return IntervalTCP value
       
   128         */    
       
   129         TInt GetIntervalTCP() const;
       
   130         
       
   131         /**
       
   132         * Getter for STUNRetransmitTimer. 
       
   133         * @since Series 60_3.1
       
   134         * @return STUN retransmit timer value.
       
   135         */
       
   136         TInt GetSTUNRetransmitTimer() const;
       
   137 
       
   138     private:
       
   139 
       
   140         void ConstructL();
       
   141 
       
   142     private: // Data
       
   143 
       
   144         /**
       
   145          * Key of the record
       
   146          */
       
   147         TUint32 iIAPKey;
       
   148 
       
   149         /**
       
   150          * Identifier of the iap table. IAP Id
       
   151          */
       
   152         TUint32 iIAPId;
       
   153         
       
   154         /**
       
   155          * NAT refresh interval for UDP in UNSAF Protocols IAP settings
       
   156          */
       
   157         TInt iIntervalUDP;
       
   158         
       
   159         /**
       
   160          * NAT refresh interval for TCP in UNSAF Protocols IAP settings
       
   161          */
       
   162         TInt iIntervalTCP;
       
   163         
       
   164         /**
       
   165          * STUN server port
       
   166          */
       
   167         TInt iSTUNRetransmitTimer;
       
   168         
       
   169         /**
       
   170          * The access point name. 
       
   171          * OMA ProvCont TO-NAPID/NAPDEF.
       
   172          * Own.
       
   173          */
       
   174         HBufC8* iNapDefName;        
       
   175         
       
   176         /**
       
   177          * NAPDEF. Pointer to IAP settings.
       
   178          * Not own.
       
   179          */
       
   180         CWPCharacteristic* iNapDef;
       
   181         
       
   182         /**
       
   183          * Uncomment this for testing.
       
   184          */
       
   185         //friend class T_NATFWTraversalAdapter;
       
   186     };