The C++ framework for developing highly scalable, high performance servers on Windows platforms.

ToString.cpp File Reference


Namespaces

namespace  JetByteTools
namespace  JetByteTools::Core

Defines

#define DETERMINE_FORMAT_STRING_A(rep, w, fU, fL)
#define DETERMINE_FORMAT_STRING_W(rep, w, fU, fL)

Typedefs

typedef unsigned __int64 PointerValueType

Enumerations

enum  DumpType { HexDump = 0x01, Printable = 0x10, Both = 0x11 }

Functions

static string InternalDumpDataA (const string &linePrefix, const BYTE *pData, size_t dataLength, size_t lineLength, DumpType dumpType, bool useCR, bool linePrefixOnFirstLine, bool lineFeedOnLastLine)
static wstring InternalDumpDataW (const wstring &linePrefix, const BYTE *pData, size_t dataLength, size_t lineLength, DumpType dumpType, bool useCR, bool linePrefixOnFirstLine, bool lineFeedOnLastLine)
unsigned short CalculateRequiredPrecision (const double value)
string ToStringA (const bool val)
wstring ToStringW (const bool val)
template<typename T>
constexpr size_t SpaceRequiredForType (const T &)
string ToStringA (const unsigned int val)
wstring ToStringW (const unsigned int val)
string ToStringA (const signed int val)
wstring ToStringW (const signed int val)
string ToStringA (const unsigned short val)
wstring ToStringW (const unsigned short val)
string ToStringA (const signed short val)
wstring ToStringW (const signed short val)
string ToStringA (const unsigned long val)
wstring ToStringW (const unsigned long val)
string ToStringA (const signed long val)
wstring ToStringW (const signed long val)
string ToStringA (const unsigned long long val)
wstring ToStringW (const unsigned long long val)
string ToStringA (const signed long long val)
wstring ToStringW (const signed long long val)
string ToStringA (const float val)
wstring ToStringW (const float val)
unsigned short ValidatePrecision (unsigned short precision)
string ToStringA (const double val, unsigned short precision)
wstring ToStringW (const double val, unsigned short precision)
string ToStringA (const long double val, unsigned short precision)
wstring ToStringW (const long double val, unsigned short precision)
string ToStringA (const void *val)
wstring ToStringW (const void *val)
bool IsUpperCaseRepresentation (const ToHexStringHexDigitRepresentation hexDigitRepresentation)
bool IncludePrefix (const ToHexStringHexDigitRepresentation hexDigitRepresentation)
bool IncludePrefixEveryByte (const ToHexStringHexDigitRepresentation hexDigitRepresentation)
bool IncludePadding (const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string PointerToStringA (const void *val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring PointerToStringW (const void *val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const unsigned char val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const unsigned char val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const signed char val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const signed char val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const unsigned int val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const unsigned int val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const signed int val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const signed int val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const unsigned short val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const unsigned short val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const signed short val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const signed short val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const unsigned long val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const unsigned long val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const signed long val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const signed long val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const unsigned long long val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const unsigned long long val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const signed long long val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const signed long long val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const void *val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const void *val, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
string ToHexStringA (const void *pData, const size_t length, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
wstring ToHexStringW (const void *pData, const size_t length, const ToHexStringHexDigitRepresentation hexDigitRepresentation)
_tstring BoolAsString (const bool value)
string BoolAsStringA (const bool value)
string ToHexA (const BYTE val)
wstring ToHexW (const BYTE val)
string MakePrintableA (const BYTE *const pData, const size_t dataLength, const size_t lineLength, const bool useCR)
wstring MakePrintableW (const BYTE *const pData, const size_t dataLength, const size_t lineLength, const bool useCR)
string DumpDataA (const BYTE *const pData, const size_t dataLength, const size_t lineLength, const bool useCR)
wstring DumpDataW (const BYTE *const pData, const size_t dataLength, const size_t lineLength, const bool useCR)
string DumpDataA (const string &linePrefix, const BYTE *const pData, const size_t dataLength, const size_t lineLength, const bool useCR, const bool linePrefixOnFirstLine, const bool lineFeedOnLastLine)
wstring DumpDataW (const wstring &linePrefix, const BYTE *const pData, const size_t dataLength, const size_t lineLength, const bool useCR, const bool linePrefixOnFirstLine, const bool lineFeedOnLastLine)
string DumpDataAsHexA (const BYTE *const pData, const size_t dataLength)
wstring DumpDataAsHexW (const BYTE *const pData, const size_t dataLength)
bool IsAllPrintable (const BYTE *pData, const size_t length)

Variables

static const string s_emptyStringLinePrefixA
static const wstring s_emptyStringLinePrefixW


Define Documentation

#define DETERMINE_FORMAT_STRING_A ( rep,
w,
fU,
fL   ) 

Value:

(IncludePrefix(rep) ?                                    \
      (IsUpperCaseRepresentation(rep) ?                     \
      (IncludePadding(rep) ? "0x%" w fU : "0x%" fU) :       \
         (IncludePadding(rep) ? "0x%" w fL : "0x%" fL)) :   \
      (IsUpperCaseRepresentation(rep) ?                     \
         (IncludePadding(rep) ? "%" w fU : "%" fU) :        \
         (IncludePadding(rep) ? "%" w fL : "%" fL)))

#define DETERMINE_FORMAT_STRING_W ( rep,
w,
fU,
fL   ) 

Value:

(IncludePrefix(rep) ?                                    \
      (IsUpperCaseRepresentation(rep) ?                     \
      (IncludePadding(rep) ? L"0x%" w fU : L"0x%" fU) :     \
         (IncludePadding(rep) ? L"0x%" w fL : L"0x%" fL)) : \
      (IsUpperCaseRepresentation(rep) ?                     \
         (IncludePadding(rep) ? L"%" w fU : L"%" fU) :      \
         (IncludePadding(rep) ? L"%" w fL : L"%" fL)))


Generated on Sun Sep 12 19:06:45 2021 for The Server Framework - v7.4 by doxygen 1.5.3