32 #ifndef _CLI_TELNET_H_ 33 #define _CLI_TELNET_H_ 62 const unsigned int UI_MaxConnections,
63 const unsigned long UL_TcpPort,
108 const bool AcceptConnection(
void);
111 const bool CloseConnection(
112 const int I_ConnectionSocket
117 const bool TerminateServer(
void);
123 const unsigned long m_ulTcpPort;
133 tk::Map<int, ConnectionInfo> m_tkConnections;
135 const unsigned int m_uiMaxConnections;
150 const bool B_AutoDelete
178 const bool CheckUp(
void)
const;
183 virtual void OnKey(
const KEY E_Key)
const;
185 virtual void PutString(
const char*
const STR_Out)
const;
187 virtual void Beep(
void)
const;
199 mutable tk::Queue<int> m_qChars;
201 mutable bool m_bWaitingForKeys;
208 #endif // _CLI_TELNET_H_
virtual void PutString(const char *const STR_Out) const
Output handler.
Main namespace of the CLI library.
virtual const KEY GetKey(void) const
Input key capture handler.
virtual ~TelnetConnection(void)
Destructor.
virtual void OnKey(const KEY E_Key) const
Handler to call when a key is received.
Non-blocking input device.
virtual void CleanScreen(void) const
Clean screen.
Telnet connection input/output device.
#define CLI_NS_END(__ns)
End a namespace definition.
LANG
Languages identifiers.
Result interface for execution contexts.
virtual const bool CloseDevice(void)
Device closure handler.
const bool ReceiveChars(void) const
Characters received from the socket.
const bool ProcessKeys(void) const
Processes input chars and converts them into keys one by one.
NonBlockingDevice class definition.
void StartServer(void)
Starts the server.
#define CLI_NS_BEGIN(__ns)
Begin a namespace definition.
virtual void OnCloseConnection(const TelnetConnection &CLI_ConnectionClosed, ExecutionContext *const PCLI_Context)=0
Execution context release handler.
virtual const bool OpenDevice(void)
Device opening handler.
void StopServer(void)
Stops the server.
virtual ~TelnetServer(void)
Destructor.
const bool CheckUp(void) const
Checks whether the connection should still be up.
virtual void Beep(void) const
Beep handler.
virtual ExecutionContext *const OnNewConnection(const TelnetConnection &CLI_NewConnection)=0
Execution context creation handler.