51
|
1 |
/*
|
|
2 |
* Copyright (c) 2006 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: States for PSC Host FSM
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
#ifndef PSCHOSTSTATES_H
|
|
19 |
#define PSCHOSTSTATES_H
|
|
20 |
|
|
21 |
#include <e32std.h>
|
|
22 |
|
|
23 |
/**
|
|
24 |
* PSC host states.
|
|
25 |
* Used as states for the finite state machine inside the host.
|
|
26 |
*/
|
|
27 |
namespace NXIMPHost
|
|
28 |
{
|
|
29 |
/**
|
|
30 |
* States for the host (internal FSA)
|
|
31 |
*/
|
|
32 |
enum THostStates
|
|
33 |
{
|
|
34 |
// actual states
|
|
35 |
EXIMPNotConnected = 0, // not connected
|
|
36 |
EXIMPConnecting, // connecting attempt ongoing
|
|
37 |
EXIMPConnected, // connected
|
|
38 |
EXIMPReconnecting, // attempting connection after nw suspend
|
|
39 |
EXIMPSuspended, // nw down
|
|
40 |
EXIMPDisconnecting, // disconnecting
|
|
41 |
|
|
42 |
// helper states
|
|
43 |
EXIMPHelperReconnectFailed // reconnecting failed
|
|
44 |
};
|
|
45 |
|
|
46 |
/**
|
|
47 |
* Operation status, needed by host FSA state changes.
|
|
48 |
* Called by operations. Used to update internal state
|
|
49 |
* of host to determine whether network connection is up, down,
|
|
50 |
* inactive or network suspended. See PSC Host-Plugin FSA in design
|
|
51 |
* document.
|
|
52 |
*/
|
|
53 |
enum THostOperationState
|
|
54 |
{
|
|
55 |
EXIMPOpNone, // generic empty state
|
|
56 |
EXIMPOpBindBegin, // bind is beginning
|
|
57 |
EXIMPOpBindEnd, // bind has ended
|
|
58 |
EXIMPOpShareBegin, // share is beginning
|
|
59 |
EXIMPOpShareEnd, // share has ended
|
|
60 |
EXIMPOpUnshareBegin, // unshare is beginning
|
|
61 |
EXIMPOpUnshareEnd, // unshare has ended
|
|
62 |
EXIMPOpReconnectBegin, // reconnect is beginning
|
|
63 |
EXIMPOpReconnectEnd, // reconnect has ended
|
|
64 |
EXIMPOpUnbindBegin, // unbind is beginning
|
|
65 |
EXIMPOpUnbindEnd, // unbind has ended
|
|
66 |
|
|
67 |
EXIMPOpSessionLostBegin, // session lost handling is beginning
|
|
68 |
EXIMPOpSessionLostEnd, // session lost handling has ended
|
|
69 |
EXIMPOpForcedTeardownBegin, // forced teardown is beginning
|
|
70 |
EXIMPOpForcedTeardownEnd, // forced teardown has ended
|
|
71 |
};
|
|
72 |
}
|
|
73 |
|
|
74 |
#endif // PSCHOSTSTATES_H
|
|
75 |
|
|
76 |
|
|
77 |
|
|
78 |
|
|
79 |
|