upnp/upnpstack/upnpconnectionmanagersession/inc/upnpconnectionmanagersession.h
changeset 0 f5a58ecadc66
equal deleted inserted replaced
-1:000000000000 0:f5a58ecadc66
       
     1 /** @file
       
     2 * Copyright (c) 2008 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:  upnpconnectionmanager / client side interface
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef R_UPNPCONNECTIONMANAGERSESSION_H
       
    19 #define R_UPNPCONNECTIONMANAGERSESSION_H
       
    20 
       
    21 #include "upnpconnectionmanagernetworkevent.h"
       
    22 #include "upnpsessionbase.h"
       
    23 
       
    24 /**
       
    25  * Client session to UPnP Connection Manager
       
    26  *
       
    27  * @lib upnpconnectionmanagersession
       
    28  * 
       
    29  * @since S60 5.0
       
    30  */
       
    31 NONSHARABLE_CLASS( RUpnpConnectionManagerSession ) : public RUpnpSessionBase
       
    32     {
       
    33 public:
       
    34 
       
    35     /**
       
    36      * Constructor.
       
    37      */
       
    38     RUpnpConnectionManagerSession();
       
    39 
       
    40     /**
       
    41      * Establish connection with server
       
    42      */
       
    43     TInt Connect();
       
    44 
       
    45     /**
       
    46      * Start RConnection if not started, otherwise do nothing
       
    47      *
       
    48      * @param aResult error code
       
    49      */
       
    50     TInt RequestEnsureStartRConnection( TInt& aResult );
       
    51 
       
    52     /**
       
    53      * Can be used to check whether RConnection has been started
       
    54      *
       
    55      * @return aResult ETrue if connection has been started
       
    56      */
       
    57     void RequestIsRConnectionStarted( TBool& aResult );
       
    58 
       
    59     /**
       
    60      * Get current iap
       
    61      *
       
    62      * @return iap
       
    63      */
       
    64     TInt RequestActiveIap();
       
    65     
       
    66     /**
       
    67      * Get current address
       
    68      *
       
    69      * @return address
       
    70      */
       
    71     TInetAddr RequestLocalAddress();        
       
    72 
       
    73     /**
       
    74      * Subscribes to network event
       
    75      *
       
    76      * @param aStatus subscribtion connection
       
    77      * @param aNetworkEvent network event
       
    78      */
       
    79     void RequestSubscribeToNetworkEvents( TRequestStatus& aStatus, 
       
    80                                           TUpnpConnectionManagerNetworkEvent& aNetworkEvent );
       
    81 
       
    82     /**
       
    83      * Cancel subscribtion for network event
       
    84      *
       
    85      */
       
    86     void RequestCancelSubscribeToNetworkEvents();
       
    87 
       
    88 private:
       
    89 
       
    90     /**
       
    91      * Pointer for the first parameter
       
    92      */
       
    93     TPtr8       iParameter0;
       
    94     
       
    95     /**
       
    96      * Pointer for the network event 
       
    97      */
       
    98     TPtr8       iNetworkEventParameter;
       
    99     
       
   100     };
       
   101 
       
   102 #endif // R_UPNPCONNECTIONMANAGERSESSION_H
       
   103 
       
   104 // End of File