wlanutilities/wlanqtutilities/wrapper/inc/wlanqtutilscmmwrapper_s60_p.h
branchGCC_SURGE
changeset 47 b3d8f88532b7
parent 34 30a5f517c615
parent 46 2fbd1d709fe7
equal deleted inserted replaced
34:30a5f517c615 47:b3d8f88532b7
     1 /*
       
     2  * Copyright (c) 2009 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 #ifndef WLANQTUTILSCMMWRAPPER_S60_P_H_
       
    18 #define WLANQTUTILSCMMWRAPPER_S60_P_H_
       
    19 
       
    20 // INCLUDES
       
    21 #include <cmmanagerext.h>
       
    22 #include "wlanqtutilscommon.h"
       
    23 
       
    24 QT_BEGIN_NAMESPACE
       
    25 
       
    26 //definitions taken from cmpluginwlandef.h and cmpluginpacketdatadef.h
       
    27 const TUint KUidPacketDataBearerType = 0x10207378;
       
    28 
       
    29 class WlanQtUtilsIap;
       
    30 class WlanQtUtilsWlanIap;
       
    31 
       
    32 // CLASS DECLARATION
       
    33 
       
    34 /**
       
    35  * CmmWrapperPrivate class.
       
    36  */
       
    37 class CmmWrapperPrivate
       
    38     {
       
    39 
       
    40 public:
       
    41 
       
    42     /**
       
    43      * Default constructor
       
    44      */
       
    45     CmmWrapperPrivate(CmmWrapper *wrapper);
       
    46 
       
    47     /**
       
    48      * Destructor
       
    49      */
       
    50     ~CmmWrapperPrivate();
       
    51 
       
    52 public:
       
    53     // New functions    
       
    54 
       
    55     /**
       
    56      * Fetches IAPs from CMM
       
    57      * 
       
    58      * @iapList, list of IAPs
       
    59      * @return error code
       
    60      */
       
    61     int fetchIaps(QList<WlanQtUtilsIap*> &iapList);
       
    62 
       
    63     /**
       
    64      * Creates a new WLAN IAP through CMM
       
    65      * 
       
    66      * @aWlanAp WLAN parameters to store in IAP
       
    67      * @return Created IAP, NULL in error cases
       
    68      */
       
    69     WlanQtUtilsWlanIap *createWlanIap(const WlanQtUtilsWlanAp *aWlanAp);
       
    70     
       
    71     /**
       
    72      * Move IAP to the Internet SNAP
       
    73      * 
       
    74      * @param[in] iapId Which IAP to move
       
    75      */
       
    76     void moveIapToInternetSnap(TInt32 aIapId);
       
    77         
       
    78 private:
       
    79 
       
    80     /**
       
    81      * Fetches IAPs from CMM, leaves in error cases
       
    82      * 
       
    83      * @iapList, list of IAPs
       
    84      */
       
    85     void fetchIapsL(QList<WlanQtUtilsIap*> &iapList);
       
    86     
       
    87     /**
       
    88      * Creates a new WLAN IAP through CMM, leaves in error cases
       
    89      * 
       
    90      * @aWlanAp WLAN parameters to store in IAP
       
    91      * @return Created IAP
       
    92      */
       
    93     WlanQtUtilsWlanIap *createWlanIapL(const WlanQtUtilsWlanAp *aWlanAp);
       
    94 
       
    95     /**
       
    96      * Move IAP to the Internet SNAP, leaves in error cases
       
    97      * 
       
    98      * @param[in] iapId Which IAP to move
       
    99      */
       
   100     void moveIapToInternetSnapL(TInt32 aIapId);
       
   101         
       
   102     /**
       
   103      * Fetches IAPs of the given SNAP from CMM
       
   104      * 
       
   105      * @param[in] aSnapId ID of the SNAP whose IAPS are requested
       
   106      * @param[out] aSnapsIapList Where to store IAPs
       
   107      * @return Error code
       
   108      */    
       
   109     int getIapListFromSnap(
       
   110         TUint32 aSnapId,
       
   111         QList<WlanQtUtilsIap*>& aSnapsIapList);
       
   112     
       
   113     /**
       
   114      * Fetches IAP information of the given ConnectionMethod from CMM
       
   115      * 
       
   116      * @param[in] aConnectionMethod Where to read info
       
   117      * @return Created IAP
       
   118      */    
       
   119     WlanQtUtilsIap *getIapInfoL(
       
   120         RCmConnectionMethodExt aConnectionMethod);
       
   121     
       
   122     /**
       
   123      * Maps CMManager's WLAN security mode into WlanQtUtilsWlanSecMode.
       
   124      * 
       
   125      * @aSecModeFromCmManager security mode read from CMManager
       
   126      * @return: Mapped security mode to be used in Wlan Qt Utilities.
       
   127      */
       
   128     WlanQtUtilsWlanSecMode cmm2WlanQtUtilsSecModeMap(int aSecModeFromCmManager);
       
   129 
       
   130     /**
       
   131      * Maps WlanQtUtilsWlanSecMode into CMManager's WLAN security mode.
       
   132      * 
       
   133      * @aWlanQtUtilsSecMode: Wlan Qt Utilities' WLAN security mode 
       
   134      * @return: Mapped CMManager's WLAN security mode.
       
   135      */
       
   136     int wlanQtUtils2CmmSecModeMap(WlanQtUtilsWlanSecMode aWlanQtUtilsSecMode);
       
   137 
       
   138 private:
       
   139     // Data
       
   140 
       
   141     /**
       
   142      * q_ptr pointer to CmmWrapper
       
   143      * Owned by CmmWrapperPrivate object, instantiated in
       
   144      * constructor.
       
   145      */
       
   146     CmmWrapper *q_ptr;
       
   147 
       
   148     RCmManagerExt iCmManagerExt;
       
   149 
       
   150     };
       
   151 
       
   152 QT_END_NAMESPACE
       
   153 
       
   154 #endif /* WLANQTUTILSCMMWRAPPER_S60_P_H_ */
       
   155 
       
   156 // End of file