|
1 // Copyright (c) 2006-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 // IPSCPR States |
|
15 // |
|
16 // |
|
17 |
|
18 /** |
|
19 @file |
|
20 @internalComponent |
|
21 */ |
|
22 |
|
23 #ifndef SYMBIAN_IPSCPRSTATES_H |
|
24 #define SYMBIAN_IPSCPRSTATES_H |
|
25 |
|
26 #include <comms-infras/corescprstates.h> |
|
27 #include <comms-infras/corescpractivities.h> |
|
28 #include "IPSCPR.h" |
|
29 #include "qos_msg.h" |
|
30 |
|
31 //-========================================================= |
|
32 // |
|
33 // States |
|
34 // |
|
35 //-========================================================= |
|
36 |
|
37 namespace QoSIpSCprActivities |
|
38 { |
|
39 enum QoSIpSCprActivityId |
|
40 { |
|
41 EQoSIpSCprOpenInternalSocket = ESock::ECFActivityCustom + 100 // + 100 to keep out of way of anything in base |
|
42 }; |
|
43 } |
|
44 |
|
45 namespace QoSIpSCprStates |
|
46 { |
|
47 typedef MeshMachine::TNodeContext<CIpSubConnectionProvider, IPBaseSCprStates::TContext> TContext; |
|
48 |
|
49 typedef MeshMachine::TAwaitingMessageState<TQoSIpSCprMessages::TOpenInternalSocket> TAwaitingOpenInternalSocket; |
|
50 typedef MeshMachine::TAwaitingMessageState<TQoSIpSCprMessages::TInternalSocketOpened> TAwaitingInternalSocketOpened; |
|
51 |
|
52 DECLARE_SERIALIZABLE_STATE( |
|
53 TNoTagBlockedByOpenInternalSocket, |
|
54 MeshMachine::TActivityIdMutex<QoSIpSCprActivities::EQoSIpSCprOpenInternalSocket>, |
|
55 MeshMachine::TNoTag |
|
56 ) |
|
57 |
|
58 DECLARE_SMELEMENT_HEADER( TNoTagOrSendApplyResponse, MeshMachine::TStateFork<TContext>, NetStateMachine::MStateFork, QoSIpSCprStates::TContext ) |
|
59 virtual TInt TransitionTag(); |
|
60 DECLARE_SMELEMENT_FOOTER( TNoTagOrSendApplyResponse ) |
|
61 |
|
62 typedef MeshMachine::TActivitiesIdMutex<QoSIpSCprActivities::EQoSIpSCprOpenInternalSocket, IPDeftSCprBaseActivities::ECFActivityAddressUpdate> TOpenInternalSocketAndAddressUpdateActivityMutex; |
|
63 |
|
64 DECLARE_SERIALIZABLE_STATE( |
|
65 TNoTagOrSendApplyResponseBlockedByOpenInternalSocketAndAddressUpdate, |
|
66 TOpenInternalSocketAndAddressUpdateActivityMutex, |
|
67 TNoTagOrSendApplyResponse |
|
68 ) |
|
69 |
|
70 DECLARE_SMELEMENT_HEADER( TAwaitingJoinComplete, MeshMachine::TState<TContext>, NetStateMachine::MState, QoSIpSCprStates::TContext ) |
|
71 virtual TBool Accept(); |
|
72 DECLARE_SMELEMENT_FOOTER( TAwaitingJoinComplete ) |
|
73 |
|
74 DECLARE_SMELEMENT_HEADER( TAwaitingLeaveComplete, MeshMachine::TState<TContext>, NetStateMachine::MState, QoSIpSCprStates::TContext ) |
|
75 virtual TBool Accept(); |
|
76 DECLARE_SMELEMENT_FOOTER( TAwaitingLeaveComplete ) |
|
77 |
|
78 DECLARE_SMELEMENT_HEADER( TAddClientToQoSChannel, MeshMachine::TStateTransition<TContext>, NetStateMachine::MStateTransition, QoSIpSCprStates::TContext ) |
|
79 virtual void DoL(); |
|
80 DECLARE_SMELEMENT_FOOTER( TAddClientToQoSChannel ) |
|
81 |
|
82 DECLARE_SMELEMENT_HEADER( TRemoveClientToQoSChannel, MeshMachine::TStateTransition<TContext>, NetStateMachine::MStateTransition, QoSIpSCprStates::TContext ) |
|
83 virtual void DoL(); |
|
84 DECLARE_SMELEMENT_FOOTER( TRemoveClientToQoSChannel ) |
|
85 |
|
86 DECLARE_SMELEMENT_HEADER( TOpenInternalSocket, MeshMachine::TStateTransition<TContext>, NetStateMachine::MStateTransition, QoSIpSCprStates::TContext ) |
|
87 virtual void DoL(); |
|
88 DECLARE_SMELEMENT_FOOTER( TOpenInternalSocket ) |
|
89 |
|
90 DECLARE_SMELEMENT_HEADER( TRemoveLeavingClientFromQoSChannel, MeshMachine::TStateTransition<TContext>, NetStateMachine::MStateTransition, QoSIpSCprStates::TContext ) |
|
91 virtual void DoL(); |
|
92 DECLARE_SMELEMENT_FOOTER( TRemoveLeavingClientFromQoSChannel ) |
|
93 |
|
94 DECLARE_SMELEMENT_HEADER( TStoreAddressUpdateAndAddClientToQoSChannel, MeshMachine::TStateTransition<TContext>, NetStateMachine::MStateTransition, QoSIpSCprStates::TContext ) |
|
95 virtual void DoL(); |
|
96 DECLARE_SMELEMENT_FOOTER( TStoreAddressUpdateAndAddClientToQoSChannel ) |
|
97 |
|
98 DECLARE_SMELEMENT_HEADER( TSetParameters, MeshMachine::TStateTransition<TContext>, NetStateMachine::MStateTransition, QoSIpSCprStates::TContext ) |
|
99 virtual void DoL(); |
|
100 DECLARE_SMELEMENT_FOOTER( TSetParameters ) |
|
101 |
|
102 DECLARE_SMELEMENT_HEADER( TBindSelfToDefaultServiceProvider, MeshMachine::TStateTransition<TContext>, NetStateMachine::MStateTransition, QoSIpSCprStates::TContext ) |
|
103 virtual void DoL(); |
|
104 DECLARE_SMELEMENT_FOOTER( TBindSelfToDefaultServiceProvider ) |
|
105 |
|
106 #ifdef SYMBIAN_ADAPTIVE_TCP_RECEIVE_WINDOW |
|
107 DECLARE_AGGREGATED_TRANSITION2( |
|
108 TStoreAndSetParameters, |
|
109 PRStates::TStoreParams, |
|
110 QoSIpSCprStates::TSetParameters |
|
111 ) |
|
112 #else |
|
113 DECLARE_AGGREGATED_TRANSITION2( |
|
114 TStoreAndSetParameters, |
|
115 SCprStates::TStoreParams, |
|
116 QoSIpSCprStates::TSetParameters |
|
117 ) |
|
118 #endif // SYMBIAN_ADAPTIVE_TCP_RECEIVE_WINDOW |
|
119 } |
|
120 |
|
121 #endif // SYMBIAN_IPSCPRSTATES_H |