39 #ifndef TIXML_STRING_INCLUDED
40 #define TIXML_STRING_INCLUDED
49 #if defined(_MSC_VER) && (_MSC_VER >= 1200 )
51 #define TIXML_EXPLICIT explicit
52 #elif defined(__GNUC__) && (__GNUC__ >= 3 )
54 #define TIXML_EXPLICIT explicit
56 #define TIXML_EXPLICIT
92 init( static_cast<size_type>( strlen(copy) ));
100 memcpy(
start(), str, len);
125 return append(suffix, static_cast<size_type>( strlen(suffix) ));
131 return append(&single, 1);
163 assert( index <
length() );
170 assert( index <
length() );
177 return find(lookup, 0);
185 for (
const char* p =
c_str() + offset; *p !=
'\0'; ++p)
241 const size_type intsNeeded = ( bytesNeeded +
sizeof(int) - 1 ) /
sizeof( int );
242 rep_ =
reinterpret_cast<Rep*
>(
new int[ intsNeeded ] );
259 delete [] (
reinterpret_cast<int*
>(
rep_ ) );
318 #endif // TIXML_STRING_INCLUDED
319 #endif // TIXML_USE_STL
size_type find(char lookup) const
const char & at(size_type index) const
bool operator>(const TiXmlString &a, const TiXmlString &b)
static const size_type npos
TiXmlString & assign(const char *str, size_type len)
TiXmlString operator+(const TiXmlString &a, const TiXmlString &b)
TIXML_EXPLICIT TiXmlString(const char *copy)
bool operator<(const TiXmlString &a, const TiXmlString &b)
void swap(TiXmlString &other)
TiXmlString & append(const char *str, size_type len)
TiXmlString & operator+=(const char *suffix)
const char * c_str() const
TinyXML class. See http://www.grinninglizard.com/tinyxml.
size_type find(char tofind, size_type offset) const
size_type capacity() const
void reserve(size_type cap)
char & operator[](size_type index) const
void init(size_type sz, size_type cap)
bool operator==(const TiXmlString &a, const TiXmlString &b)
TiXmlString(const TiXmlString ©)
TiXmlOutStream & operator<<(const TiXmlString &in)
TiXmlString & operator=(const char *copy)
bool operator>=(const TiXmlString &a, const TiXmlString &b)
void set_size(size_type sz)
const char * data() const
bool operator!=(const TiXmlString &a, const TiXmlString &b)
TinyXML class. See http://www.grinninglizard.com/tinyxml.
TinyXML class. See http://www.grinninglizard.com/tinyxml.
bool operator<=(const TiXmlString &a, const TiXmlString &b)
TIXML_EXPLICIT TiXmlString(const char *str, size_type len)