ezEngine  Milestone 7
ezHybridString< Size, AllocatorWrapper > Class Template Reference

#include <String.h>

Inheritance diagram for ezHybridString< Size, AllocatorWrapper >:

Public Member Functions

 ezHybridString (ezAllocatorBase *pAllocator)
 
 ezHybridString (const ezHybridString< Size, AllocatorWrapper > &other)
 
 ezHybridString (const ezHybridStringBase< Size > &other)
 
 ezHybridString (const char *rhs)
 
 ezHybridString (const wchar_t *rhs)
 
 ezHybridString (const ezStringView &rhs)
 
 ezHybridString (const ezStringBuilder &rhs)
 
 ezHybridString (ezStringBuilder &&rhs)
 
 ezHybridString (ezHybridString< Size, AllocatorWrapper > &&other)
 
 ezHybridString (ezHybridStringBase< Size > &&other)
 
void operator= (const ezHybridString< Size, AllocatorWrapper > &rhs)
 
void operator= (const ezHybridStringBase< Size > &rhs)
 
void operator= (const char *szString)
 
void operator= (const wchar_t *szString)
 
void operator= (const ezStringView &rhs)
 
void operator= (const ezStringBuilder &rhs)
 
void operator= (ezStringBuilder &&rhs)
 
void operator= (ezHybridString< Size, AllocatorWrapper > &&rhs)
 
void operator= (ezHybridStringBase< Size > &&rhs)
 
- Public Member Functions inherited from ezHybridStringBase< Size >
 operator ezStringView () const
 Returns a string view to this string's data.
 
 operator const char * () const
 Returns a pointer to the internal Utf8 string.
 
void Clear ()
 Resets this string to an empty string. More...
 
const char * GetData () const
 Returns a pointer to the internal Utf8 string.
 
ezUInt32 GetElementCount () const
 Returns the amount of bytes that this string takes (excluding the '\0' terminator).
 
ezUInt32 GetCharacterCount () const
 Returns the number of characters in this string.
 
ezStringView GetSubString (ezUInt32 uiFirstCharacter, ezUInt32 uiNumCharacters) const
 Returns an iterator to a sub-string of this string, starting at character uiFirstCharacter, up until uiFirstCharacter + uiNumCharacters. More...
 
ezStringView GetFirst (ezUInt32 uiNumCharacters) const
 Returns an iterator to the sub-string containing the first uiNumCharacters characters of this string. More...
 
ezStringView GetLast (ezUInt32 uiNumCharacters) const
 Returns an iterator to the sub-string containing the last uiNumCharacters characters of this string. More...
 
void ReadAll (ezStreamReaderBase &Stream)
 Replaces the current string with the content from the stream. Reads the stream to its end.
 
ezUInt64 GetHeapMemoryUsage () const
 Returns the amount of bytes that are currently allocated on the heap.
 
- Public Member Functions inherited from ezStringBase< ezHybridStringBase< Size > >
bool IsEmpty () const
 Returns whether the string is an empty string.
 
bool StartsWith (const char *szStartsWith) const
 Returns true, if this string starts with the given string.
 
bool StartsWith_NoCase (const char *szStartsWith) const
 Returns true, if this string starts with the given string. Case insensitive.
 
bool EndsWith (const char *szEndsWith) const
 Returns true, if this string ends with the given string.
 
bool EndsWith_NoCase (const char *szEndsWith) const
 Returns true, if this string ends with the given string. Case insensitive.
 
const char * FindSubString (const char *szStringToFind, const char *szStartSearchAt=nullptr) const
 
const char * FindSubString_NoCase (const char *szStringToFind, const char *szStartSearchAt=nullptr) const
 
const char * FindLastSubString (const char *szStringToFind, const char *szStartSearchAt=nullptr) const
 
const char * FindLastSubString_NoCase (const char *szStringToFind, const char *szStartSearchAt=nullptr) const
 
const char * FindWholeWord (const char *szSearchFor, ezStringUtils::EZ_CHARACTER_FILTER IsDelimiterCB, const char *szStartSearchAt=nullptr) const
 Searches for the word szSearchFor. If IsDelimiterCB returns true for both characters in front and back of the word, the position is returned. Otherwise nullptr.
 
const char * FindWholeWord_NoCase (const char *szSearchFor, ezStringUtils::EZ_CHARACTER_FILTER IsDelimiterCB, const char *szStartSearchAt=nullptr) const
 Searches for the word szSearchFor. If IsDelimiterCB returns true for both characters in front and back of the word, the position is returned. Otherwise nullptr. Ignores case.
 
ezInt32 Compare (const char *pString2) const
 Compares this string with the other one. Returns 0 for equality, -1 if this string is 'smaller', 1 otherwise.
 
ezInt32 CompareN (const char *pString2, ezUInt32 uiCharsToCompare) const
 Compares up to a given number of characters of this string with the other one. Returns 0 for equality, -1 if this string is 'smaller', 1 otherwise.
 
ezInt32 Compare_NoCase (const char *pString2) const
 Compares this string with the other one. Returns 0 for equality, -1 if this string is 'smaller', 1 otherwise. Case insensitive.
 
ezInt32 CompareN_NoCase (const char *pString2, ezUInt32 uiCharsToCompare) const
 Compares up to a given number of characters of this string with the other one. Returns 0 for equality, -1 if this string is 'smaller', 1 otherwise. Case insensitive.
 
bool IsEqual (const char *pString2) const
 Compares this string with the other string for equality.
 
bool IsEqualN (const char *pString2, ezUInt32 uiCharsToCompare) const
 Compares up to a given number of characters of this string with the other string for equality. Case insensitive.
 
bool IsEqual_NoCase (const char *pString2) const
 Compares this string with the other string for equality.
 
bool IsEqualN_NoCase (const char *pString2, ezUInt32 uiCharsToCompare) const
 Compares up to a given number of characters of this string with the other string for equality. Case insensitive.
 
const char * ComputeCharacterPosition (ezUInt32 uiCharacterIndex) const
 Computes the pointer to the n-th character in the string. This is a linear search from the start.
 
iterator GetIteratorFront () const
 Returns an iterator to this string, which points to the very first character. More...
 
reverse_iterator GetIteratorBack () const
 Returns an iterator to this string, which points to the very last character (NOT the end). More...
 

Additional Inherited Members

- Public Types inherited from ezStringBase< ezHybridStringBase< Size > >
typedef ezStringIterator
< ezHybridStringBase< Size > > 
iterator
 
typedef ezStringIterator
< ezHybridStringBase< Size > > 
const_iterator
 
typedef
ezStringReverseIterator
< ezHybridStringBase< Size > > 
reverse_iterator
 
typedef
ezStringReverseIterator
< ezHybridStringBase< Size > > 
const_reverse_iterator
 
- Protected Member Functions inherited from ezHybridStringBase< Size >
 ezHybridStringBase (ezAllocatorBase *pAllocator)
 Creates an empty string.
 
 ezHybridStringBase (const ezHybridStringBase &rhs, ezAllocatorBase *pAllocator)
 Copies the data from rhs.
 
 ezHybridStringBase (ezHybridStringBase &&rhs, ezAllocatorBase *pAllocator)
 Moves the data from rhs.
 
 ezHybridStringBase (const char *rhs, ezAllocatorBase *pAllocator)
 Copies the data from rhs.
 
 ezHybridStringBase (const wchar_t *rhs, ezAllocatorBase *pAllocator)
 Copies the data from rhs.
 
 ezHybridStringBase (const ezStringView &rhs, ezAllocatorBase *pAllocator)
 Copies the data from rhs.
 
 ezHybridStringBase (const ezStringBuilder &rhs, ezAllocatorBase *pAllocator)
 Copies the data from rhs.
 
 ezHybridStringBase (ezStringBuilder &&rhs, ezAllocatorBase *pAllocator)
 Moves the data from rhs.
 
 ~ezHybridStringBase ()
 Destructor.
 
void operator= (const ezHybridStringBase &rhs)
 Copies the data from rhs.
 
void operator= (ezHybridStringBase &&rhs)
 Moves the data from rhs.
 
void operator= (const char *rhs)
 Copies the data from rhs.
 
void operator= (const wchar_t *rhs)
 Copies the data from rhs.
 
void operator= (const ezStringView &rhs)
 Copies the data from rhs.
 
void operator= (const ezStringBuilder &rhs)
 Copies the data from rhs.
 
void operator= (ezStringBuilder &&rhs)
 Moves the data from rhs.
 

Detailed Description

template<ezUInt16 Size, typename AllocatorWrapper = ezDefaultAllocatorWrapper>
class ezHybridString< Size, AllocatorWrapper >

See Also
ezHybridStringBase

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