32 #ifndef _CLI_IO_DEVICE_H_ 33 #define _CLI_IO_DEVICE_H_ 186 OPENING_CURLY_BRACE =
'{',
187 CLOSING_CURLY_BRACE =
'}',
188 OPENING_BRACKET =
'[',
189 CLOSING_BRACKET =
']',
261 const char*
const STR_DbgName,
262 const bool B_AutoDelete
347 const std::string& STR_Out
354 const tk::String& STR_Out
360 const char*
const STR_Out
378 const uint8_t UI8_Out
384 const int16_t I16_Out
390 const uint16_t UI16_Out
396 const int32_t I32_Out
402 const uint32_t UI32_Out
408 const int64_t I64_Out
414 const uint64_t UI64_Out
432 const void*
const PV_Out
480 const bool B_TrueCls,
481 const bool B_WrapLines
483 m_iWidth(I_Width), m_iHeight(I_Height),
484 m_bTrueCls(B_TrueCls), m_bWrapLines(B_WrapLines)
502 m_iWidth = CLI_ScreenInfo.m_iWidth;
503 m_iHeight = CLI_ScreenInfo.m_iHeight;
504 m_bTrueCls = CLI_ScreenInfo.m_bTrueCls;
505 m_bWrapLines = CLI_ScreenInfo.m_bWrapLines;
538 virtual void PutString(
const char*
const STR_Out)
const = 0;
541 virtual void Beep(
void)
const;
561 const tk::String m_strDebugName;
586 const char*
const STR_DbgName,
587 const bool B_AutoDelete
605 virtual const KEY GetKey(
void)
const = 0;
644 #endif // _CLI_IO_DEVICE_H_
static OutputDevice & GetStdErr(void)
Standard error device singleton.
static OutputDevice & GetNullDevice(void)
Null device singleton.
Main namespace of the CLI library.
virtual ~IODevice(void)
Destructor.
virtual ~OutputDevice(void)
Destructor.
Based on utf-8 encoding for '§' (changed in version 2.9)
Based on utf-8 encoding for 'à' (changed in version 2.9)
virtual void Beep(void) const
Beep handler.
const bool GetbWrapLines(void) const
Line wrapping characteristic accessor.
Based on utf-8 encoding for '€' (changed in version 2.9)
Based on utf-8 encoding for 'í' (changed in version 2.9)
static OutputDevice & GetStdOut(void)
Standard output device singleton.
Based on utf-8 encoding for 'ì' (changed in version 2.9)
virtual const KEY GetKey(void) const =0
Input key capture handler.
virtual const bool WouldOutput(const OutputDevice &CLI_Device) const
Stack overflow protection.
static IODevice & GetNullDevice(void)
Null device singleton.
Based on utf-8 encoding for 'ç' (changed in version 2.9)
const bool OpenUp(const CallInfo &CLI_CallInfo)
Checks the device is opened.
virtual const bool OpenDevice(void)=0
Device opening handler.
Based on utf-8 encoding for 'ü' (changed in version 2.9)
const bool CloseDown(const CallInfo &CLI_CallInfo)
Indicates the device the client does not need the device to opened anymore.
#define CLI_NS_END(__ns)
End a namespace definition.
const int GetInstanceUsers(void) const
Instance user count accessor.
const OutputDevice & operator<<(const std::string &STR_Out) const
Output operator.
const KEY Char2Key(const int I_Char) const
Common char translation.
Based on utf-8 encoding for '£' (changed in version 2.9)
Based on utf-8 encoding for 'á' (changed in version 2.9)
virtual const bool CloseDevice(void)=0
Device closure handler.
Based on utf-8 encoding for 'ô' (changed in version 2.9)
ScreenInfo(const int I_Width, const int I_Height, const bool B_TrueCls, const bool B_WrapLines)
Constructor.
Based on utf-8 encoding for '©' (changed in version 2.9)
IOEndl(void)
Default constructor.
const int GetHeight(void) const
Screen height accessor.
const int GetOpenUsers(void) const
Open state user count accessor.
const unsigned int GetSafeHeight(void) const
Safe screen height accessor.
Based on utf-8 encoding for 'ï' (changed in version 2.9)
End of line for input/output devices.
virtual const ResourceString GetLocation(void) const
Input location accessor.
const ResourceString GetLastError(void) const
Last error accessor.
Based on utf-8 encoding for 'ü' (changed in version 2.9)
_RegularValues
ScreenInfo regular values.
ScreenInfo(const ScreenInfo &CLI_Info)
Copy constructor.
virtual void CleanScreen(void) const
Clean screen.
static IODevice & GetStdIn(void)
Standard input device singleton.
Based on utf-8 encoding for 'ä' (changed in version 2.9)
Unknown value constant for either width or height.
Clean screen key (changed from 129 to 501 in order to avoid overlap with printable ASCII characters)...
virtual const ScreenInfo GetScreenInfo(void) const
Screen info accessor.
ResourceString m_cliLastError
Based on utf-8 encoding for 'ò' (changed in version 2.9)
Based on utf-8 encoding for 'µ' (changed in version 2.9)
#define CLI_NS_BEGIN(__ns)
Begin a namespace definition.
const int FreeInstance(const CallInfo &CLI_CallInfo)
Releases the instance.
Based on utf-8 encoding for 'û' (changed in version 2.9)
Based on utf-8 encoding for 'â' (changed in version 2.9)
const unsigned int GetSafeWidth(void) const
Safe screen width accessor.
Based on utf-8 encoding for 'é' (changed in version 2.9)
const bool GetbTrueCls(void) const
True CleanScreen() characteristic accessor.
Based on utf-8 encoding for 'ù' (changed in version 2.9)
Based on utf-8 encoding for '²' (changed in version 2.9)
Key to chararcters encoder.
Based on utf-8 encoding for '°' (changed in version 2.9)
Backspace (changed from '\b' to 8 in version 2.7 for ASCII compliance).
Based on utf-8 encoding for 'è' (changed in version 2.9)
Based on utf-8 encoding for 'ú' (changed in version 2.9)
Regular characters to key decoder.
const int UseInstance(const CallInfo &CLI_CallInfo)
Ensures instance validity.
virtual ~ScreenInfo(void)
Destructor.
ScreenInfo & operator=(const ScreenInfo &CLI_ScreenInfo)
Assignment operator.
Based on utf-8 encoding for 'î' (changed in version 2.9)
Generic input/output device.
Based on utf-8 encoding for 'û' (changed in version 2.9)
virtual void PutString(const char *const STR_Out) const =0
Output handler.
const int GetWidth(void) const
Screen width accessor.
const IOEndl endl
The common IOEndl object.
Insert key (changed from 500 to 502 in order to avoid overlap with printable ASCII characters)...
Based on utf-8 encoding for 'ö' (changed in version 2.9)
const tk::String GetDebugName(void) const
Debug name accessor.
Return code while analyzing input characters, till the encoding sequence is not fulfilled.
Based on utf-8 encoding for 'ó' (changed in version 2.9)
virtual const bool WouldInput(const IODevice &CLI_Device) const
Stack overflow protection.
Delete key (changed from 128 to 127 in version 2.7 for ASCII compliance).