26
|
1 |
/*
|
|
2 |
* Copyright (c) 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 |
* Initial Contributors:
|
|
9 |
* Nokia Corporation - initial contribution.
|
|
10 |
*
|
|
11 |
* Contributors:
|
|
12 |
*
|
|
13 |
* Description :
|
|
14 |
*
|
|
15 |
* CCFUNCommandHandler class declaration for AT+CFUN command
|
|
16 |
*
|
|
17 |
*/
|
|
18 |
|
|
19 |
#ifndef CFUNCOMMANDHANDLER_H
|
|
20 |
#define CFUNCOMMANDHANDLER_H
|
|
21 |
|
32
|
22 |
#include <e32property.h>
|
|
23 |
|
|
24 |
#include "atcmdasyncbase.h"
|
26
|
25 |
|
|
26 |
const TInt KGeneralProfileId = 0;
|
|
27 |
const TInt KOfflineProfileId = 5;
|
|
28 |
|
|
29 |
class MProfileEngine;
|
|
30 |
|
|
31 |
/**
|
|
32 |
* AT+CFUN command handler implementation class
|
|
33 |
*/
|
|
34 |
NONSHARABLE_CLASS( CCFUNCommandHandler ) : public CATCmdAsyncBase
|
|
35 |
{
|
|
36 |
public:
|
|
37 |
static CCFUNCommandHandler* NewL(MATMiscCmdPlugin* aCallback, TAtCommandParser& aATCmdParser, RMobilePhone& aPhone);
|
|
38 |
~CCFUNCommandHandler();
|
|
39 |
|
|
40 |
private: // methods from CActive
|
|
41 |
virtual void RunL();
|
|
42 |
virtual void DoCancel();
|
|
43 |
// RunError not needed as RunL does not leave
|
32
|
44 |
|
|
45 |
private: // method from CATCmdAsyncBase::MATCmdBase
|
26
|
46 |
virtual void HandleCommand( const TDesC8& aCmd, RBuf8& aReply, TBool aReplyNeeded );
|
|
47 |
|
|
48 |
private:
|
|
49 |
CCFUNCommandHandler(MATMiscCmdPlugin* aCallback, TAtCommandParser& aATCmdParser, RMobilePhone& aPhone);
|
|
50 |
void ConstructL();
|
|
51 |
|
32
|
52 |
TInt ActivateProfile(TInt aFunc);
|
26
|
53 |
TInt SetActiveProfile(TInt aProfileId);
|
|
54 |
TInt RestartDevice();
|
|
55 |
|
|
56 |
private:
|
|
57 |
RBuf8 iReply;
|
|
58 |
|
|
59 |
MProfileEngine* iProfileEngine;
|
32
|
60 |
RProperty iProperty;
|
|
61 |
TInt iExpectedState;
|
|
62 |
TInt iReset; // default 0 - do not reset the MT before setting it to <fun> power level
|
26
|
63 |
};
|
|
64 |
|
|
65 |
#endif /* CFUNCOMMANDHANDLER_H */
|