LibreOffice Module oox (master)  1
Static Public Member Functions | List of all members
oox::dump::StringHelper Class Reference

Static helper functions for formatted output to strings. More...

#include <dumperbase.hxx>

Static Public Member Functions

static void appendChar (OUStringBuffer &rStr, sal_Unicode cChar, sal_Int32 nCount)
 
static void appendString (OUStringBuffer &rStr, const OUString &rData, sal_Int32 nWidth, sal_Unicode cFill= ' ')
 
static void appendDec (OUStringBuffer &rStr, sal_uInt8 nData, sal_Int32 nWidth=0, sal_Unicode cFill= ' ')
 
static void appendDec (OUStringBuffer &rStr, sal_Int8 nData, sal_Int32 nWidth=0, sal_Unicode cFill= ' ')
 
static void appendDec (OUStringBuffer &rStr, sal_uInt16 nData, sal_Int32 nWidth=0, sal_Unicode cFill= ' ')
 
static void appendDec (OUStringBuffer &rStr, sal_Int16 nData, sal_Int32 nWidth=0, sal_Unicode cFill= ' ')
 
static void appendDec (OUStringBuffer &rStr, sal_uInt32 nData, sal_Int32 nWidth=0, sal_Unicode cFill= ' ')
 
static void appendDec (OUStringBuffer &rStr, sal_Int32 nData, sal_Int32 nWidth=0, sal_Unicode cFill= ' ')
 
static void appendDec (OUStringBuffer &rStr, sal_uInt64 nData, sal_Int32 nWidth=0, sal_Unicode cFill= ' ')
 
static void appendDec (OUStringBuffer &rStr, sal_Int64 nData, sal_Int32 nWidth=0, sal_Unicode cFill= ' ')
 
static void appendDec (OUStringBuffer &rStr, double fData, sal_Int32 nWidth=0, sal_Unicode cFill= ' ')
 
static void appendHex (OUStringBuffer &rStr, sal_uInt8 nData, bool bPrefix=true)
 
static void appendHex (OUStringBuffer &rStr, sal_Int8 nData, bool bPrefix=true)
 
static void appendHex (OUStringBuffer &rStr, sal_uInt16 nData, bool bPrefix=true)
 
static void appendHex (OUStringBuffer &rStr, sal_Int16 nData, bool bPrefix=true)
 
static void appendHex (OUStringBuffer &rStr, sal_uInt32 nData, bool bPrefix=true)
 
static void appendHex (OUStringBuffer &rStr, sal_Int32 nData, bool bPrefix=true)
 
static void appendHex (OUStringBuffer &rStr, sal_uInt64 nData, bool bPrefix=true)
 
static void appendHex (OUStringBuffer &rStr, sal_Int64 nData, bool bPrefix=true)
 
static void appendHex (OUStringBuffer &rStr, double fData, bool bPrefix=true)
 
static void appendShortHex (OUStringBuffer &rStr, sal_uInt8 nData, bool bPrefix=true)
 
static void appendShortHex (OUStringBuffer &rStr, sal_Int8 nData, bool bPrefix=true)
 
static void appendShortHex (OUStringBuffer &rStr, sal_uInt16 nData, bool bPrefix=true)
 
static void appendShortHex (OUStringBuffer &rStr, sal_Int16 nData, bool bPrefix=true)
 
static void appendShortHex (OUStringBuffer &rStr, sal_uInt32 nData, bool bPrefix=true)
 
static void appendShortHex (OUStringBuffer &rStr, sal_Int32 nData, bool bPrefix=true)
 
static void appendShortHex (OUStringBuffer &rStr, sal_uInt64 nData, bool bPrefix=true)
 
static void appendShortHex (OUStringBuffer &rStr, sal_Int64 nData, bool bPrefix=true)
 
static void appendShortHex (OUStringBuffer &rStr, double fData, bool bPrefix=true)
 
static void appendBin (OUStringBuffer &rStr, sal_uInt8 nData, bool bDots=true)
 
static void appendBin (OUStringBuffer &rStr, sal_Int8 nData, bool bDots=true)
 
static void appendBin (OUStringBuffer &rStr, sal_uInt16 nData, bool bDots=true)
 
static void appendBin (OUStringBuffer &rStr, sal_Int16 nData, bool bDots=true)
 
static void appendBin (OUStringBuffer &rStr, sal_uInt32 nData, bool bDots=true)
 
static void appendBin (OUStringBuffer &rStr, sal_Int32 nData, bool bDots=true)
 
static void appendBin (OUStringBuffer &rStr, sal_uInt64 nData, bool bDots=true)
 
static void appendBin (OUStringBuffer &rStr, sal_Int64 nData, bool bDots=true)
 
static void appendBin (OUStringBuffer &rStr, double fData, bool bDots=true)
 
template<typename Type >
static void appendFix (OUStringBuffer &rStr, Type nData, sal_Int32 nWidth=0)
 
static void appendBool (OUStringBuffer &rStr, bool bData)
 
template<typename Type >
static void appendValue (OUStringBuffer &rStr, Type nData, FormatType eFmtType)
 
static void appendCChar (OUStringBuffer &rStr, sal_Unicode cChar, bool bPrefix=true)
 
static void appendEncChar (OUStringBuffer &rStr, sal_Unicode cChar, sal_Int32 nCount, bool bPrefix=true)
 
static void appendEncString (OUStringBuffer &rStr, const OUString &rData, bool bPrefix=true)
 
static void appendToken (OUStringBuffer &rStr, std::u16string_view rToken, sal_Unicode cSep=OOX_DUMP_LISTSEP)
 
static void appendIndex (OUStringBuffer &rStr, sal_Int64 nIdx)
 
static OUString getToken (const OUString &rData, sal_Int32 &rnPos, sal_Unicode cSep=OOX_DUMP_LISTSEP)
 
static void enclose (OUStringBuffer &rStr, sal_Unicode cOpen, sal_Unicode cClose= '\0')
 Encloses the passed string with the passed characters. More...
 
static OUString trimSpaces (const OUString &rStr)
 
static OUString trimTrailingNul (const OUString &rStr)
 
static OString convertToUtf8 (std::u16string_view rStr)
 
static DataType convertToDataType (std::u16string_view rStr)
 
static FormatType convertToFormatType (std::u16string_view rStr)
 
static bool convertFromDec (sal_Int64 &ornData, const OUString &rData)
 
static bool convertFromHex (sal_Int64 &ornData, const OUString &rData)
 
static bool convertStringToInt (sal_Int64 &ornData, const OUString &rData)
 
static bool convertStringToDouble (double &orfData, const OUString &rData)
 
static bool convertStringToBool (const OUString &rData)
 
static OUStringPair convertStringToPair (const OUString &rString, sal_Unicode cSep= '=')
 
static void convertStringToStringList (OUStringVector &orVec, const OUString &rData, bool bIgnoreEmpty)
 
static void convertStringToIntList (Int64Vector &orVec, const OUString &rData, bool bIgnoreEmpty)
 

Detailed Description

Static helper functions for formatted output to strings.

Definition at line 244 of file dumperbase.hxx.

Member Function Documentation

void oox::dump::StringHelper::appendBin ( OUStringBuffer &  rStr,
sal_uInt8  nData,
bool  bDots = true 
)
static

Definition at line 383 of file dumperbase.cxx.

Referenced by appendBin(), appendValue(), and oox::dump::Output::writeBin().

void oox::dump::StringHelper::appendBin ( OUStringBuffer &  rStr,
sal_Int8  nData,
bool  bDots = true 
)
static

Definition at line 393 of file dumperbase.cxx.

References appendBin().

void oox::dump::StringHelper::appendBin ( OUStringBuffer &  rStr,
sal_uInt16  nData,
bool  bDots = true 
)
static

Definition at line 398 of file dumperbase.cxx.

References appendBin().

void oox::dump::StringHelper::appendBin ( OUStringBuffer &  rStr,
sal_Int16  nData,
bool  bDots = true 
)
static

Definition at line 406 of file dumperbase.cxx.

References appendBin().

void oox::dump::StringHelper::appendBin ( OUStringBuffer &  rStr,
sal_uInt32  nData,
bool  bDots = true 
)
static

Definition at line 411 of file dumperbase.cxx.

References appendBin().

void oox::dump::StringHelper::appendBin ( OUStringBuffer &  rStr,
sal_Int32  nData,
bool  bDots = true 
)
static

Definition at line 419 of file dumperbase.cxx.

References appendBin().

void oox::dump::StringHelper::appendBin ( OUStringBuffer &  rStr,
sal_uInt64  nData,
bool  bDots = true 
)
static

Definition at line 424 of file dumperbase.cxx.

References appendBin().

void oox::dump::StringHelper::appendBin ( OUStringBuffer &  rStr,
sal_Int64  nData,
bool  bDots = true 
)
static

Definition at line 432 of file dumperbase.cxx.

References appendBin().

void oox::dump::StringHelper::appendBin ( OUStringBuffer &  rStr,
double  fData,
bool  bDots = true 
)
static

Definition at line 437 of file dumperbase.cxx.

References appendBin(), and oox::dump::lcl_ConvertDouble().

void oox::dump::StringHelper::appendBool ( OUStringBuffer &  rStr,
bool  bData 
)
static

Definition at line 444 of file dumperbase.cxx.

Referenced by appendValue(), and oox::dump::Output::writeBool().

void oox::dump::StringHelper::appendCChar ( OUStringBuffer &  rStr,
sal_Unicode  cChar,
bool  bPrefix = true 
)
static

Definition at line 451 of file dumperbase.cxx.

References appendHex().

Referenced by appendEncChar(), and appendEncString().

void oox::dump::StringHelper::appendChar ( OUStringBuffer &  rStr,
sal_Unicode  cChar,
sal_Int32  nCount 
)
static

Definition at line 195 of file dumperbase.cxx.

References nCount, and nIndex.

Referenced by appendEncChar(), appendString(), oox::dump::Output::incIndent(), and oox::dump::Output::tab().

void oox::dump::StringHelper::appendDec ( OUStringBuffer &  rStr,
sal_uInt8  nData,
sal_Int32  nWidth = 0,
sal_Unicode  cFill = ' ' 
)
static
void oox::dump::StringHelper::appendDec ( OUStringBuffer &  rStr,
sal_Int8  nData,
sal_Int32  nWidth = 0,
sal_Unicode  cFill = ' ' 
)
static

Definition at line 214 of file dumperbase.cxx.

References appendString().

void oox::dump::StringHelper::appendDec ( OUStringBuffer &  rStr,
sal_uInt16  nData,
sal_Int32  nWidth = 0,
sal_Unicode  cFill = ' ' 
)
static

Definition at line 219 of file dumperbase.cxx.

References appendString().

void oox::dump::StringHelper::appendDec ( OUStringBuffer &  rStr,
sal_Int16  nData,
sal_Int32  nWidth = 0,
sal_Unicode  cFill = ' ' 
)
static

Definition at line 224 of file dumperbase.cxx.

References appendString().

void oox::dump::StringHelper::appendDec ( OUStringBuffer &  rStr,
sal_uInt32  nData,
sal_Int32  nWidth = 0,
sal_Unicode  cFill = ' ' 
)
static

Definition at line 229 of file dumperbase.cxx.

References appendString().

void oox::dump::StringHelper::appendDec ( OUStringBuffer &  rStr,
sal_Int32  nData,
sal_Int32  nWidth = 0,
sal_Unicode  cFill = ' ' 
)
static

Definition at line 234 of file dumperbase.cxx.

References appendString().

void oox::dump::StringHelper::appendDec ( OUStringBuffer &  rStr,
sal_uInt64  nData,
sal_Int32  nWidth = 0,
sal_Unicode  cFill = ' ' 
)
static

Definition at line 239 of file dumperbase.cxx.

References aBuffer, and appendString().

void oox::dump::StringHelper::appendDec ( OUStringBuffer &  rStr,
sal_Int64  nData,
sal_Int32  nWidth = 0,
sal_Unicode  cFill = ' ' 
)
static

Definition at line 251 of file dumperbase.cxx.

References appendString().

void oox::dump::StringHelper::appendDec ( OUStringBuffer &  rStr,
double  fData,
sal_Int32  nWidth = 0,
sal_Unicode  cFill = ' ' 
)
static

Definition at line 256 of file dumperbase.cxx.

References appendString().

void oox::dump::StringHelper::appendEncChar ( OUStringBuffer &  rStr,
sal_Unicode  cChar,
sal_Int32  nCount,
bool  bPrefix = true 
)
static

Definition at line 467 of file dumperbase.cxx.

References appendCChar(), appendChar(), and nCount.

Referenced by oox::dump::Output::writeChar().

void oox::dump::StringHelper::appendEncString ( OUStringBuffer &  rStr,
const OUString &  rData,
bool  bPrefix = true 
)
static
template<typename Type >
void oox::dump::StringHelper::appendFix ( OUStringBuffer &  rStr,
Type  nData,
sal_Int32  nWidth = 0 
)
static

Definition at line 354 of file dumperbase.hxx.

References appendDec().

Referenced by appendValue(), and oox::dump::Output::writeFix().

void oox::dump::StringHelper::appendHex ( OUStringBuffer &  rStr,
sal_uInt8  nData,
bool  bPrefix = true 
)
static
void oox::dump::StringHelper::appendHex ( OUStringBuffer &  rStr,
sal_Int8  nData,
bool  bPrefix = true 
)
static

Definition at line 271 of file dumperbase.cxx.

References appendHex().

void oox::dump::StringHelper::appendHex ( OUStringBuffer &  rStr,
sal_uInt16  nData,
bool  bPrefix = true 
)
static

Definition at line 276 of file dumperbase.cxx.

References appendHex().

void oox::dump::StringHelper::appendHex ( OUStringBuffer &  rStr,
sal_Int16  nData,
bool  bPrefix = true 
)
static

Definition at line 282 of file dumperbase.cxx.

References appendHex().

void oox::dump::StringHelper::appendHex ( OUStringBuffer &  rStr,
sal_uInt32  nData,
bool  bPrefix = true 
)
static

Definition at line 287 of file dumperbase.cxx.

References appendHex().

void oox::dump::StringHelper::appendHex ( OUStringBuffer &  rStr,
sal_Int32  nData,
bool  bPrefix = true 
)
static

Definition at line 293 of file dumperbase.cxx.

References appendHex().

void oox::dump::StringHelper::appendHex ( OUStringBuffer &  rStr,
sal_uInt64  nData,
bool  bPrefix = true 
)
static

Definition at line 298 of file dumperbase.cxx.

References appendHex().

void oox::dump::StringHelper::appendHex ( OUStringBuffer &  rStr,
sal_Int64  nData,
bool  bPrefix = true 
)
static

Definition at line 304 of file dumperbase.cxx.

References appendHex().

void oox::dump::StringHelper::appendHex ( OUStringBuffer &  rStr,
double  fData,
bool  bPrefix = true 
)
static

Definition at line 320 of file dumperbase.cxx.

References appendHex(), and oox::dump::lcl_ConvertDouble().

void oox::dump::StringHelper::appendIndex ( OUStringBuffer &  rStr,
sal_Int64  nIdx 
)
static

Definition at line 521 of file dumperbase.cxx.

References appendDec().

Referenced by oox::dump::Output::writeItemName().

void oox::dump::StringHelper::appendShortHex ( OUStringBuffer &  rStr,
sal_uInt8  nData,
bool  bPrefix = true 
)
static
void oox::dump::StringHelper::appendShortHex ( OUStringBuffer &  rStr,
sal_Int8  nData,
bool  bPrefix = true 
)
static

Definition at line 332 of file dumperbase.cxx.

References appendHex().

void oox::dump::StringHelper::appendShortHex ( OUStringBuffer &  rStr,
sal_uInt16  nData,
bool  bPrefix = true 
)
static

Definition at line 337 of file dumperbase.cxx.

References appendHex(), and SAL_MAX_UINT8.

void oox::dump::StringHelper::appendShortHex ( OUStringBuffer &  rStr,
sal_Int16  nData,
bool  bPrefix = true 
)
static

Definition at line 345 of file dumperbase.cxx.

References appendShortHex().

void oox::dump::StringHelper::appendShortHex ( OUStringBuffer &  rStr,
sal_uInt32  nData,
bool  bPrefix = true 
)
static

Definition at line 350 of file dumperbase.cxx.

References appendHex(), appendShortHex(), and SAL_MAX_UINT16.

void oox::dump::StringHelper::appendShortHex ( OUStringBuffer &  rStr,
sal_Int32  nData,
bool  bPrefix = true 
)
static

Definition at line 358 of file dumperbase.cxx.

References appendShortHex().

void oox::dump::StringHelper::appendShortHex ( OUStringBuffer &  rStr,
sal_uInt64  nData,
bool  bPrefix = true 
)
static

Definition at line 363 of file dumperbase.cxx.

References appendHex(), appendShortHex(), and SAL_MAX_UINT32.

void oox::dump::StringHelper::appendShortHex ( OUStringBuffer &  rStr,
sal_Int64  nData,
bool  bPrefix = true 
)
static

Definition at line 371 of file dumperbase.cxx.

References appendShortHex().

void oox::dump::StringHelper::appendShortHex ( OUStringBuffer &  rStr,
double  fData,
bool  bPrefix = true 
)
static

Definition at line 376 of file dumperbase.cxx.

References appendHex().

void oox::dump::StringHelper::appendString ( OUStringBuffer &  rStr,
const OUString &  rData,
sal_Int32  nWidth,
sal_Unicode  cFill = ' ' 
)
static

Definition at line 201 of file dumperbase.cxx.

References appendChar().

Referenced by appendDec().

void oox::dump::StringHelper::appendToken ( OUStringBuffer &  rStr,
std::u16string_view  rToken,
sal_Unicode  cSep = OOX_DUMP_LISTSEP 
)
static
template<typename Type >
void oox::dump::StringHelper::appendValue ( OUStringBuffer &  rStr,
Type  nData,
FormatType  eFmtType 
)
static
bool oox::dump::StringHelper::convertFromDec ( sal_Int64 &  ornData,
const OUString &  rData 
)
static

Definition at line 669 of file dumperbase.cxx.

Referenced by convertStringToInt().

bool oox::dump::StringHelper::convertFromHex ( sal_Int64 &  ornData,
const OUString &  rData 
)
static

Definition at line 692 of file dumperbase.cxx.

Referenced by convertStringToInt().

bool oox::dump::StringHelper::convertStringToBool ( const OUString &  rData)
static
bool oox::dump::StringHelper::convertStringToDouble ( double &  orfData,
const OUString &  rData 
)
static

Definition at line 718 of file dumperbase.cxx.

Referenced by oox::dump::SharedConfigData::createUnitConverter().

bool oox::dump::StringHelper::convertStringToInt ( sal_Int64 &  ornData,
const OUString &  rData 
)
static
void oox::dump::StringHelper::convertStringToIntList ( Int64Vector orVec,
const OUString &  rData,
bool  bIgnoreEmpty 
)
static

Definition at line 769 of file dumperbase.cxx.

References convertStringToInt(), and getToken().

Referenced by oox::dump::NameListBase::exclude().

OUStringPair oox::dump::StringHelper::convertStringToPair ( const OUString &  rString,
sal_Unicode  cSep = '=' 
)
static
void oox::dump::StringHelper::convertStringToStringList ( OUStringVector orVec,
const OUString &  rData,
bool  bIgnoreEmpty 
)
static
DataType oox::dump::StringHelper::convertToDataType ( std::u16string_view  rStr)
static
FormatType oox::dump::StringHelper::convertToFormatType ( std::u16string_view  rStr)
static
OString oox::dump::StringHelper::convertToUtf8 ( std::u16string_view  rStr)
static

Definition at line 620 of file dumperbase.cxx.

References OUStringToOString().

Referenced by oox::dump::OutputObjectBase::writeValueItem().

void oox::dump::StringHelper::enclose ( OUStringBuffer &  rStr,
sal_Unicode  cOpen,
sal_Unicode  cClose = '\0' 
)
static

Encloses the passed string with the passed characters.

Uses cOpen, if cClose is NUL.

Definition at line 533 of file dumperbase.cxx.

Referenced by oox::dump::InputObjectBase::dumpGuid(), oox::dump::ConstList::implGetName(), oox::dump::FlagsList::implGetName(), oox::dump::CombiList::implGetName(), and oox::dump::OutputObjectBase::writeStringItem().

OUString oox::dump::StringHelper::getToken ( const OUString &  rData,
sal_Int32 &  rnPos,
sal_Unicode  cSep = OOX_DUMP_LISTSEP 
)
static

Definition at line 528 of file dumperbase.cxx.

References trimSpaces().

Referenced by convertStringToIntList(), and convertStringToStringList().

OUString oox::dump::StringHelper::trimSpaces ( const OUString &  rStr)
static
OUString oox::dump::StringHelper::trimTrailingNul ( const OUString &  rStr)
static

The documentation for this class was generated from the following files: