telephonyprotocols/pdplayer/inc/pdpcpravailabilitylistener.h
changeset 0 3553901f7fa8
child 24 6638e7f4bd8f
equal deleted inserted replaced
-1:000000000000 0:3553901f7fa8
       
     1 // Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 // PDP Connection Provider implementation
       
    15 // 
       
    16 //
       
    17 
       
    18 /**
       
    19  @file
       
    20  @internalComponent
       
    21 */
       
    22 
       
    23 
       
    24 #ifndef PDPCPRAVAILABILITYLISTENER_H_
       
    25 #define PDPCPRAVAILABILITYLISTENER_H_
       
    26 
       
    27 #include <e32base.h>
       
    28 #include <etel.h>
       
    29 #include <etelmm.h>
       
    30 #include <etelpckt.h>
       
    31 #include "PDPProvision.h"
       
    32 #include "MPDPCPRBearerObserver.h"
       
    33 
       
    34 class CPDPCPRDynamicCapsListener : public CActive
       
    35 	{
       
    36 public:
       
    37 	static CPDPCPRDynamicCapsListener* NewL(const CTSYProvision* aTsyProvision);
       
    38 	~CPDPCPRDynamicCapsListener();
       
    39 	TUint DynamicCaps();
       
    40 	void NotifyDynamicCapsChange(MPDPCPRBearerObserver* aObserver);
       
    41 	TBool IsDynamicCapsSupported();
       
    42 	
       
    43 	// CActive
       
    44 	void RunL();
       
    45 	void DoCancel();
       
    46 	TInt RunError(TInt aError);
       
    47 
       
    48 private:
       
    49 	CPDPCPRDynamicCapsListener(const CTSYProvision* aTsyProvision);
       
    50 	void ConstructL();
       
    51 	void GetPhoneInfoL();
       
    52 	void InitialiseDynamicCaps();
       
    53 	
       
    54 private:
       
    55 	RTelServer iTelServer;
       
    56 	RTelServer::TPhoneInfo iPhoneInfo;
       
    57 	RMobilePhone iPhone;
       
    58 	RPacketService iPacketService;
       
    59 	RPacketService::TStatus iPacketServiceStatus;
       
    60 	const CTSYProvision* iTsyProvision;
       
    61 	MPDPCPRBearerObserver* iObserver;
       
    62 	RPacketService::TDynamicCapsFlags iDynCaps;		// TDynamicCapsFlags is TUint typedef
       
    63 	};
       
    64 
       
    65 
       
    66 class CPDPCPRNetworkModeListener : public CActive
       
    67 	{
       
    68 public:
       
    69 	static CPDPCPRNetworkModeListener* NewL(const CTSYProvision* aTsyProvision);
       
    70 	~CPDPCPRNetworkModeListener();
       
    71 	RMobilePhone::TMobilePhoneNetworkMode NetworkMode();
       
    72 	void NotifyNetworkModeChange(MPDPCPRBearerObserver* aObserver);
       
    73 	
       
    74 	// CActive
       
    75 	void RunL();
       
    76 	void DoCancel();
       
    77 	TInt RunError(TInt aError);
       
    78 
       
    79 private:
       
    80 	CPDPCPRNetworkModeListener(const CTSYProvision* aTsyProvision);
       
    81 	void ConstructL();
       
    82 	void GetPhoneInfoL();
       
    83 	void InitialiseNetworkMode();
       
    84 	
       
    85 private:
       
    86 	RTelServer iTelServer;
       
    87 	RTelServer::TPhoneInfo iPhoneInfo;
       
    88 	RMobilePhone iPhone;
       
    89 	const CTSYProvision* iTsyProvision;
       
    90 	MPDPCPRBearerObserver* iObserver;
       
    91 	RMobilePhone::TMobilePhoneNetworkMode iNetworkMode;
       
    92 	};
       
    93 
       
    94 #endif /*PDPCPRAVAILABILITYLISTENER_H_*/