wlanutilities/wlanqtutilities/wrapper/inc/wlanqtutilsconmonwrapper.h
branchRCL_3
changeset 25 f28ada11abbf
parent 24 63be7eb3fc78
equal deleted inserted replaced
24:63be7eb3fc78 25:f28ada11abbf
     1 /*
       
     2 * Copyright (c) 2009-2010 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 * Wrapper for Symbian Connection Monitor library.
       
    16 */
       
    17 
       
    18 #ifndef WLANQTUTILSCONMONWRAPPER_H
       
    19 #define WLANQTUTILSCONMONWRAPPER_H
       
    20 
       
    21 // System includes
       
    22 
       
    23 #include <QObject>
       
    24 #include <QList>
       
    25 #include <QSharedPointer>
       
    26 #include <QScopedPointer>
       
    27 
       
    28 // User includes
       
    29 
       
    30 #include "wlanqtutils.h"
       
    31 
       
    32 // Forward declarations
       
    33 
       
    34 class WlanQtUtilsAp;
       
    35 class WlanQtUtilsConnection;
       
    36 class WlanQtUtilsConMonWrapperInfo;
       
    37 class WlanQtUtilsConMonWrapperDisconnect;
       
    38 
       
    39 // External data types
       
    40 
       
    41 // Constants
       
    42 
       
    43 // Class declaration
       
    44 
       
    45 class WlanQtUtilsConMonWrapper : public QObject
       
    46 {
       
    47     Q_OBJECT
       
    48     
       
    49 public:
       
    50 
       
    51     // Data types
       
    52 
       
    53     explicit WlanQtUtilsConMonWrapper(QObject *parent = 0);
       
    54     
       
    55     ~WlanQtUtilsConMonWrapper();
       
    56 
       
    57     WlanQtUtilsConnection *activeConnection() const;
       
    58 
       
    59     WlanQtUtilsConnection *connectionInfo(uint connectionId) const;
       
    60 
       
    61     void disconnectIap(int iapId);
       
    62         
       
    63 signals:
       
    64 
       
    65     /*!
       
    66        Signal indicating that a new connection has been created.
       
    67 
       
    68        @param [in] connectionId Connection ID.
       
    69      */
       
    70     void connCreatedEventFromWrapper(uint connectionId);
       
    71 
       
    72     /*!
       
    73        Signal indicating that a connection has been deleted.
       
    74 
       
    75        @param [in] connectionId Connection ID.
       
    76      */
       
    77     void connDeletedEventFromWrapper(uint connectionId);
       
    78 
       
    79     /*!
       
    80        Signal indicating that status of a connection has changed.
       
    81 
       
    82        @param [in] connectionId Connection ID.
       
    83        @param [in] connectionStatus Connection status.
       
    84      */
       
    85     void connStatusEventFromWrapper(
       
    86         uint connectionId,
       
    87         WlanQtUtils::ConnStatus connectionStatus);
       
    88 
       
    89 public slots:
       
    90 
       
    91 protected:
       
    92 
       
    93 protected slots:
       
    94 
       
    95 private:
       
    96 
       
    97 private slots:
       
    98 
       
    99 private: // data
       
   100     
       
   101     // Owned data
       
   102     
       
   103     //! Private implementation of connection info interface
       
   104     QScopedPointer<WlanQtUtilsConMonWrapperInfo> d_ptrInfo;
       
   105 
       
   106     //! Private implementation of connection disconnect interface
       
   107     QScopedPointer<WlanQtUtilsConMonWrapperDisconnect> d_ptrDisconnect;
       
   108 
       
   109     // Friend classes
       
   110     
       
   111     // Friend classes in order to be able to emit public signals directly
       
   112     // from private implementation classes.
       
   113     friend class WlanQtUtilsConMonWrapperInfo;
       
   114     
       
   115     // This is defined as a friend class in order to be able to call
       
   116     // event handlers of wrappers from unit tests.
       
   117     friend class TestWlanQtUtils;
       
   118 };
       
   119 
       
   120 #endif // WLANQTUTILSCONMONWRAPPER_H