|
1 /* |
|
2 * Copyright (c) 2003-2004 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: Subsession for Command Handler notify. |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef CPHSRVSUBSESSIONCOMHANDNOTIFY_H |
|
19 #define CPHSRVSUBSESSIONCOMHANDNOTIFY_H |
|
20 |
|
21 |
|
22 // INCLUDES |
|
23 #include "CPhSrvSubSessionBase.h" |
|
24 #include "MPhSrvComHandInitiators.h" |
|
25 |
|
26 // CLASS DECLARATION |
|
27 |
|
28 /** |
|
29 * Command handler Subsession. |
|
30 * |
|
31 * @since 2.6 |
|
32 */ |
|
33 class CPhSrvSubSessionCommandHandlerNotify |
|
34 : public CPhSrvSubSessionBase, |
|
35 public MPhSrvComHandInitiator |
|
36 { |
|
37 public: // Constructors and destructor |
|
38 |
|
39 /** |
|
40 * Two-phased constructor. |
|
41 * |
|
42 * @return CPhSrvSubSessionCommandHandlerNotify subsession. |
|
43 */ |
|
44 static CPhSrvSubSessionBase* NewL( |
|
45 CPhSrvSession& aSession ); |
|
46 |
|
47 /** |
|
48 * Destructor. |
|
49 * |
|
50 */ |
|
51 ~CPhSrvSubSessionCommandHandlerNotify(); |
|
52 |
|
53 |
|
54 private: // Functions from base classes |
|
55 |
|
56 /** |
|
57 * @see MPhSrvMessageDecoder |
|
58 */ |
|
59 TBool PhSrvMessageDecoderCanProcessMessage( TInt aFunction ); |
|
60 |
|
61 /** |
|
62 * @see MPhSrvMessageProcessor |
|
63 */ |
|
64 void PhSrvMessageProcessorHandleMessageL( const RMessage2& aMessage ); |
|
65 |
|
66 /** |
|
67 * @see MPhSrvComHandInitiator |
|
68 */ |
|
69 void InitiatorMakeAsynchronousComHandRequest( |
|
70 const TPhCltComHandCommandParameters& |
|
71 aParams ); |
|
72 |
|
73 /** |
|
74 * @see MPhSrvComHandInitiator |
|
75 */ |
|
76 TBool InitiatorIsReadyToPerformRequest() const; |
|
77 |
|
78 |
|
79 private: // SubSession function handlers |
|
80 |
|
81 void CmdSubSessionClose( const RMessage2& aMessage ); |
|
82 |
|
83 void CmdSubSessionComHandNotifyRequestL( |
|
84 const RMessage2& aMessage ); |
|
85 |
|
86 void CmdSubSessionComHandNotifyRequestCancelL( |
|
87 const RMessage2& aMessage ); |
|
88 |
|
89 void CmdSubSessionComHandNotifyReportL( |
|
90 const RMessage2& aMessage ); |
|
91 |
|
92 |
|
93 private: |
|
94 |
|
95 /** |
|
96 * Constructor. |
|
97 * |
|
98 * @param aSession The session where this subsession belongs. |
|
99 */ |
|
100 CPhSrvSubSessionCommandHandlerNotify( CPhSrvSession& aSession ); |
|
101 |
|
102 |
|
103 |
|
104 private: // Data |
|
105 |
|
106 // Indicates whether we have an pending request |
|
107 TBool iHavePendingComHandRequestPointer; |
|
108 |
|
109 // Initialized when the phone app engine is |
|
110 // ready to handle command handler requests. |
|
111 RMessage2 iPendingComHandRequestPointer; |
|
112 |
|
113 }; |
|
114 |
|
115 |
|
116 #endif // CPHSRVSUBSESSIONCOMHANDNOTIFY_H |
|
117 |
|
118 |
|
119 // End of File |