You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
93 lines
746 B
93 lines
746 B
/* Messages used by the Terminal and TerminalManager classes. */
|
|
|
|
|
|
|
|
#ifndef MSG_H
|
|
|
|
#define MSG_H
|
|
|
|
|
|
|
|
enum MsgType
|
|
|
|
{
|
|
|
|
CREATE_TERMINAL,
|
|
|
|
DELETE_TERMINAL,
|
|
|
|
RUN_DIAGNOSTICS,
|
|
|
|
PERFORM_SWITCHOVER
|
|
|
|
};
|
|
|
|
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
/*...*/
|
|
|
|
int msgType;
|
|
|
|
int terminalType;
|
|
|
|
int terminalId;
|
|
|
|
int otherTerminalId;
|
|
|
|
int terminalStatus;
|
|
|
|
} Msg;
|
|
|
|
|
|
|
|
/* Message used to create a terminal. */
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
Msg header;
|
|
|
|
}TerminalCreateMsg;
|
|
|
|
|
|
|
|
/* Acknowledgement to Terminal Create message. */
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
Msg header;
|
|
|
|
} TerminalCreateAck;
|
|
|
|
|
|
|
|
/* Terminal Delete message */
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
Msg header;
|
|
|
|
} TerminalDeleteMsg;
|
|
|
|
|
|
|
|
|
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
Msg header;
|
|
|
|
} RunDiagnosticsMsg;
|
|
|
|
#endif
|