Universal output to console class. This class provides a universal output interface with support for various data types, formatting options, and multiple output devices (console, buffer).
More...
|
|
| PICout (int controls=PICoutManipulators::DefaultControls, PICoutStdStream stream=PICoutStdStream::StdOut) |
| | Default constructor with default features (AddSpaces and AddNewLine)
|
| |
|
| PICout (bool active, PICoutStdStream stream=PICoutStdStream::StdOut) |
| | Construct with default features (AddSpaces and AddNewLine), but if "active" is false does nothing.
|
| |
|
PICout & | operator<< (const char *v) |
| | Output operator for strings with "const char * " type.
|
| |
|
PICout & | operator<< (const PIString &v) |
| | Output operator for PIString.
|
| |
|
PICout & | operator<< (bool v) |
| | Output operator for boolean values.
|
| |
|
PICout & | operator<< (char v) |
| | Output operator for "char" values.
|
| |
|
PICout & | operator<< (uchar v) |
| | Output operator for "unsigned char" values.
|
| |
|
PICout & | operator<< (short v) |
| | Output operator for "short" values.
|
| |
|
PICout & | operator<< (ushort v) |
| | Output operator for "unsigned short" values.
|
| |
|
PICout & | operator<< (int v) |
| | Output operator for "int" values Outputs an integer value to the configured stream with optional format (binary, octal, decimal, hexadecimal).
|
| |
|
PICout & | operator<< (uint v) |
| | Output operator for "unsigned int" values Outputs an unsigned integer value to the configured stream with optional format (binary, octal, decimal, hexadecimal).
|
| |
|
PICout & | operator<< (long v) |
| | Output operator for "long" values Outputs a long integer value to the configured stream with optional format (binary, octal, decimal, hexadecimal).
|
| |
|
PICout & | operator<< (ulong v) |
| | Output operator for "unsigned long" values Outputs an unsigned long integer value to the configured stream with optional format (binary, octal, decimal, hexadecimal).
|
| |
|
PICout & | operator<< (llong v) |
| | Output operator for "long long" values Outputs a long long integer value to the configured stream with optional format (binary, octal, decimal, hexadecimal).
|
| |
|
PICout & | operator<< (ullong v) |
| | Output operator for "unsigned long long" values Outputs an unsigned long long integer value to the configured stream with optional format (binary, octal, decimal, hexadecimal).
|
| |
|
PICout & | operator<< (float v) |
| | Output operator for "float" values.
|
| |
|
PICout & | operator<< (double v) |
| | Output operator for "double" values.
|
| |
|
PICout & | operator<< (ldouble v) |
| | Output operator for "ldouble" values.
|
| |
|
PICout & | operator<< (const void *v) |
| | Output operator for pointers Outputs a pointer address to the configured stream in hexadecimal format.
|
| |
|
PICout & | operator<< (const PIObject *v) |
| | Output operator for PIObject and ancestors Outputs a PIObject or its descendants to the configured stream, including class name and object name.
|
| |
|
PICout & | operator<< (PICoutManipulators::PICoutSpecialChar v) |
| | Output operator for PICoutSpecialChar values.
|
| |
|
PICout & | operator<< (PIFlags< PICoutManipulators::PICoutFormat > v) |
| | Output operator for PIFlags<PICoutFormat> values Sets output format flags (binary, octal, decimal, hexadecimal, bold, colors) for subsequent integer output.
|
| |
|
PICout & | operator<< (PICoutManipulators::PICoutFormat v) |
| | Output operator for PICoutFormat values Sets output format flag (binary, octal, decimal, hexadecimal, bold, colors) for subsequent integer output.
|
| |
| PICout & | operator<< (PICoutManipulators::PICoutAction v) |
| | Do some action. More...
|
| |
|
PICout & | setControl (PICoutManipulators::PICoutControl c, bool on=true) |
| | Set control flag "c" is "on" state.
|
| |
|
PICout & | setControls (PICoutManipulators::PICoutControls c) |
| | Set control flags "c".
|
| |
|
PICout & | saveAndSetControls (PICoutManipulators::PICoutControls c) |
| | Exec saveControls() and set control flags to "c".
|
| |
| PICout & | saveControls () |
| | Save control flags to internal stack Saves the current control flags to an internal stack for later restoration using restoreControls(). More...
|
| |
| PICout & | restoreControls () |
| | Restore control flags from internal stack Restores the control flags from the internal stack that were previously saved using saveControls(). More...
|
| |
| PICout & | space () |
| | Conditional put space character to output Conditionally adds a space character to the output if the AddSpaces control flag is enabled. More...
|
| |
| PICout & | quote () |
| | Conditional put quote character to output Conditionally adds quote characters to the output if the AddQuotes control flag is enabled. More...
|
| |
| PICout & | newLine () |
| | Conditional put new line character to output Conditionally adds a newline character to the output if the AddNewLine control flag is enabled. More...
|
| |
|
PICout & | write (char c) |
| | Write char Writes a single character directly to the output stream without any formatting.
|
| |
|
PICout & | write (const char *str) |
| | Write raw data Writes raw C-style string data directly to the output stream without any formatting.
|
| |
|
PICout & | write (const char *str, int len) |
| | Write raw data Writes raw data of specified length directly to the output stream without any formatting.
|
| |
|
PICout & | write (const PIString &s) |
| | Write raw PIString Writes raw PIString data directly to the output stream without any formatting.
|
| |
|
(Note that these are not member functions.)
|
|
PICout | operator<< (PICout s, const PISystemMonitor::ThreadStats &v) |
| | Output operator to PICout.
|
| |
|
template<typename T > |
| PICout | operator<< (PICout s, const PIDeque< T > &v) |
| | Output operator to PICout.
|
| |
|
template<typename Key , typename Type > |
| PICout | operator<< (PICout s, const PIMap< Key, Type > &v) |
| | Output operator to PICout.
|
| |
|
template<typename Type0 , typename Type1 > |
| PICout | operator<< (PICout s, const PIPair< Type0, Type1 > &v) |
| | Output operator to PICout.
|
| |
|
template<typename T > |
| PICout | operator<< (PICout s, const PIVector< T > &v) |
| | Output operator to PICout.
|
| |
|
template<typename T > |
| PICout | operator<< (PICout s, const PIVector2D< T > &v) |
| | Output operator for PIVector2D to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIBinaryLog::BinLogInfo &bi) |
| | Writes PIBinaryLog::BinLogInfo summary to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIDir &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIFile::FileInfo &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PISerial::DeviceInfo &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIUSB::Endpoint &v) |
| | Writes endpoint description to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIBaseTransfer::Part &v) |
| | Writes Part to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIFileTransfer::PFTFileInfo &v) |
| | Output PICout operator for PFTFileInfo.
|
| |
|
template<typename Type > |
| PICout | operator<< (PICout &s, const PILine< Type > &v) |
| | Writes segment coordinates to PICout.
|
| |
|
template<typename T > |
| PICout | operator<< (PICout s, const complex< T > &v) |
| | Writes a complex number as (real; imag).
|
| |
|
template<typename Type > |
| PICout | operator<< (PICout &s, const PIPoint< Type > &v) |
| | Writes point coordinates to PICout.
|
| |
|
template<typename Type > |
| PICout | operator<< (PICout &s, const PIRect< Type > &v) |
| | Writes rectangle description to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIJSON &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PISystemInfo::MountInfo &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIConstChars &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIStringList &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIBitArray &ba) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PITime &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIDate &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIDateTime &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PINetworkAddress &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PISystemTime &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PISystemTime::Frequency &f) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIValueTree &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIVariant &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIVariantTypes::Enumerator &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIVariantTypes::Enum &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIVariantTypes::File &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIVariantTypes::Dir &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIVariantTypes::Color &v) |
| | Output operator to PICout.
|
| |
|
PICout | operator<< (PICout s, const PIVariantTypes::IODevice &v) |
| | Output operator to PICout.
|
| |
Universal output to console class. This class provides a universal output interface with support for various data types, formatting options, and multiple output devices (console, buffer).
Synopsis
This class provide many stream operators for output with some features. Output to PICout is thread-sequential, i.e. doesn`t mixed from parallel threads.
Features
- support text formatting (color, style)
- insertion spaces between entries
- insertion new line at the end of output
- strings are quoted
- custom output operator can be easily written
- can outpur to console, internal buffer or both
Usage
int a = 10, b = 32, c = 11;
<< "quotes";
PICout(int controls=PICoutManipulators::DefaultControls, PICoutStdStream stream=PICoutStdStream::StdOut)
Default constructor with default features (AddSpaces and AddNewLine)
Definition: picout.cpp:180
Namespace contains enums that controls PICout.
Definition: picout.h:70
@ Bin
Definition: picout.h:115
@ Hex
Definition: picout.h:118
@ Tab
Definition: picout.h:78
@ AddNewLine
Definition: picout.h:104
@ AddQuotes
Definition: picout.h:105
@ AddSpaces
Definition: picout.h:103
@ Default
Definition: piscreentypes.h:45
@ Green
Definition: piscreentypes.h:48
#define piCout
Definition: picout.h:36
Writing your own output operator
for (uint i = 0; i < ba.size(); ++i)
}
The PIByteArray class provides an array of bytes with efficient memory management and various manipul...
Definition: pibytearray.h:42
Universal output to console class. This class provides a universal output interface with support for ...
Definition: picout.h:166
PICout & operator<<(const char *v)
Output operator for strings with "const char * " type.
Definition: picout.cpp:448
return s
Store operator.
Definition: pisystemmonitor.h:312