18#if !defined(XALANDOMSTRING_HEADER_GUARD_1357924680)
19#define XALANDOMSTRING_HEADER_GUARD_1357924680
70 const char* theString,
82 const XalanDOMChar* theString,
92 clone(MemoryManager& theManager);
127 return m_data.begin();
135 return m_data.begin();
143 return m_data.empty() ==
true ? m_data.end() : m_data.end() - 1;
151 return m_data.empty() ==
true ? m_data.end() : m_data.end() - 1;
161 if (m_data.empty() ==
false)
169 const_reverse_iterator
176 if (m_data.empty() ==
false)
189 return m_data.rend();
192 const_reverse_iterator
197 return m_data.rend();
227 XalanDOMChar theChar);
234 resize(theCount, XalanDOMChar(0));
245 return theCapacity == 0 ? 0 :
size_type(theCapacity - 1);
253 m_data.reserve(theCount + 1);
261 m_data.erase(m_data.begin(), m_data.end());
273 m_data.erase(thePosition);
289 m_data.erase(theFirst, theLast);
291 m_size = m_data.size() - 1;
308 return m_size == 0 ? true :
false;
316 return m_data[theIndex];
324 return m_data[theIndex];
332 return m_data.at(theIndex);
340 return m_data.at(theIndex);
348 return m_data.empty() ==
true ? &s_empty : &m_data[0];
364 m_data.swap(theOther.m_data);
366 std::swap(m_size, theOther.m_size);
403 const XalanDOMChar* theSource,
412 return append(theSource, theCount);
429 const char* theSource,
438 return append(theSource, theCount);
452 if (&theSource !=
this)
454 m_data = theSource.m_data;
456 m_size = theSource.m_size;
467 XalanDOMChar theChar)
475 return append(theCount, theChar);
495 assert(thePosition < theSource.
length() &&
498 return append(theSource.
c_str() + thePosition, theCount);
503 const XalanDOMChar* theString,
514 const char* theString,
526 XalanDOMChar theChar);
553 return insert(thePosition1, theString.
c_str() + thePosition2, theCount);
559 const XalanDOMChar* theString,
565 const XalanDOMChar* theString)
567 return insert(thePosition, theString,
length(theString));
574 XalanDOMChar theChar);
579 XalanDOMChar theChar);
585 XalanDOMChar theChar);
601 (thePosition + theCount <=
length()));
605 return theSubstring.
assign(
640 return compare(thePosition1, theCount1, theString.
c_str() + thePosition2, theCount2);
650 const XalanDOMChar* theString,
655 reset(MemoryManager& theManager,
const char* theString);
658 reset(MemoryManager& theManager,
const XalanDOMChar* theString);
690 return m_data.getMemoryManager();
701 const XalanDOMChar* theString,
704 assert(theString != 0);
711 const XalanDOMChar* theLHS,
713 const XalanDOMChar* theRHS,
718 const XalanDOMChar* theLHS,
719 const XalanDOMChar* theRHS)
732 const XalanDOMChar* theRHS)
739 const XalanDOMChar* theLHS,
776 assert((m_data.empty() ==
true && m_size == 0) || m_size == m_data.size() - 1);
777 assert(m_data.empty() ==
true || m_data.back() == 0);
791 return m_data.empty() ==
true ? m_data.end() : m_data.end() - 1;
799 return m_data.empty() ==
true ? m_data.end() : m_data.end() - 1;
807 return m_data.begin() + thePosition;
815 return m_data.begin() + thePosition;
818#if defined (XALAN_DEVELOPMENT)
831 static const XalanDOMChar s_empty;
847 return theKey.
hash();
864 assert (theKey != 0);
866 return theKey->
hash();
938 return theLHS.
compare(theRHS) < 0 ? true :
false;
956 assert(theLHS != 0 && theRHS != 0);
976 assert(theLHS != 0 && theRHS != 0);
978 return theLHS->
compare(*theRHS) < 0 ? true :
false;
1006 const XalanDOMChar* theRHS)
1015 const XalanDOMChar* theLHS,
1029 return !(theLHS == theRHS);
1036 const XalanDOMChar* theLHS,
1039 return !(theLHS == theRHS);
1047 const XalanDOMChar* theRHS)
1049 return !(theRHS == theLHS);
1054inline XalanDOMString&
1056 const XalanDOMString& theLHS,
1057 const XalanDOMString& theRHS,
1058 XalanDOMString& result)
1060 result.assign(theLHS);
1062 return result += theRHS;
1067inline XalanDOMString&
1069 const XalanDOMString& theLHS,
1070 const XalanDOMChar* theRHS,
1071 XalanDOMString& result)
1073 result.assign(theLHS);
1075 return result += theRHS;
1080inline XalanDOMString&
1082 const XalanDOMChar* theLHS,
1083 const XalanDOMString& theRHS,
1084 XalanDOMString& result)
1086 result.assign(theLHS);
1088 return result += theRHS;
1093inline const XalanDOMString&
1096 const XalanDOMString& theRHS,
1097 XalanDOMString& result)
1099 result.assign(theLHS);
1101 result.append(theRHS);
1108inline const XalanDOMString&
1110 const XalanDOMString& theLHS,
1112 XalanDOMString& result)
1114 result.assign(theLHS);
1116 result.append(theRHS);
1145 const XalanDOMChar* theSourceString,
1148 bool terminate = false);
1165 const XalanDOMChar* theSourceString,
1169 char theSubstitutionChar);
1179#if !defined(XALAN_DEVELOPMENT)
1182 const char* theSourceString,
1202 const XalanDOMChar* theSourceString,
1204 bool terminate = false);
1217 const XalanDOMChar* theSourceString,
1220 char theSubstitutionChar);
1230#if !defined(XALAN_DEVELOPMENT)
1256 bool terminate =
false)
1259 theSourceString.
c_str(),
1280 char theSubstitutionChar);
1292#if !defined(XALAN_DEVELOPMENT)
1314inline const XalanDOMString&
1316 const char* theSourceString,
1320 theResult.
assign(theSourceString, theSourceStringLength);
1340 const
char* theSourceString,
1343 bool terminate = false);
1357 const
char* theSourceString,
1359 bool terminate = false);
1375 const
char* theSourceString,
1377 bool theSourceStringIsNullTerminated,
1379 bool terminate = false);
#define XALAN_DOM_EXPORT_FUNCTION(T)
#define XALAN_DEFAULT_CONSTRUCTOR_MEMMGR
#define XALAN_DEFAULT_MEMMGR
#define XALAN_USES_MEMORY_MANAGER(Type)
XalanDOMException(ExceptionCode code=UNKNOWN_ERR)
Constructor which takes an error code and a message.
virtual ~TranscodingError()
const_iterator getBackInsertIterator() const
const XalanDOMChar * c_str() const
void push_back(XalanDOMChar theChar)
XalanDOMString & insert(size_type thePosition, const XalanDOMString &theString)
void transcode(CharVectorType &theResult) const
Transcode the string to the local code page.
XalanDOMString(const char *theString, MemoryManager &theManager XALAN_DEFAULT_MEMMGR, size_type theCount=size_type(npos))
XalanDOMString & operator+=(const XalanDOMChar *theString)
const XalanDOMChar * data() const
XalanDOMString & assign(const XalanDOMString &theSource)
size_type max_size() const
int compare(const XalanDOMChar *theString) const
int compare(size_type thePosition1, size_type theCount1, const XalanDOMString &theString) const
const_reference at(size_type theIndex) const
XalanDOMString & assign(iterator theFirstPosition, iterator theLastPosition)
static bool equals(const XalanDOMString &theLHS, const XalanDOMString &theRHS)
int compare(size_type thePosition1, size_type theCount1, const XalanDOMString &theString, size_type thePosition2, size_type theCount2) const
XalanDOMString & assign(const XalanDOMString &theSource, size_type thePosition, size_type theCount)
XalanDOMCharVectorType::iterator iterator
XalanDOMString & append(const char *theString)
iterator erase(iterator theFirst, iterator theLast)
XalanDOMString & operator+=(const XalanDOMString &theSource)
XalanDOMString & operator=(const char *theRHS)
iterator insert(iterator thePosition, XalanDOMChar theChar)
const_iterator end() const
XalanDOMString & assign(const XalanDOMChar *theSource, size_type theCount)
XalanDOMString(const XalanDOMChar *theString, MemoryManager &theManager XALAN_DEFAULT_MEMMGR, size_type theCount=size_type(npos))
XalanDOMString & substr(XalanDOMString &theSubstring, size_type thePosition=0, size_type theCount=size_type(npos)) const
iterator getBackInsertIterator()
reverse_iterator rbegin()
XalanDOMString & operator=(const XalanDOMString &theRHS)
XalanDOMString & append(const XalanDOMString &theSource)
XalanDOMString & append(const XalanDOMString &theSource, size_type thePosition, size_type theCount)
XalanDOMString & insert(size_type thePosition1, const XalanDOMString &theString, size_type thePosition2, size_type theCount)
const_reverse_iterator rbegin() const
static bool equals(const XalanDOMString &theLHS, const XalanDOMChar *theRHS)
static bool equals(const XalanDOMChar *theLHS, size_type theLHSLength, const XalanDOMChar *theRHS, size_type theRHSLength)
static size_type length(const char *theString)
iterator getIteratorForPosition(size_type thePosition)
XalanDOMString & append(const char *theString, size_type theCount)
XalanDOMString & insert(size_type thePosition, const XalanDOMChar *theString)
XalanDOMString(MemoryManager &theManager XALAN_DEFAULT_CONSTRUCTOR_MEMMGR)
XalanDOMString & erase(size_type theStartPosition=0, size_type theCount=size_type(npos))
XalanVector< char > CharVectorType
size_type capacity() const
static size_t hash(const XalanDOMChar *theString, size_type theLength)
const_reverse_iterator rend() const
void reserve(size_type theCount=0)
iterator erase(iterator thePosition)
XalanDOMString & assign(size_type theCount, XalanDOMChar theChar)
XalanDOMString & insert(size_type thePosition, size_type theCount, XalanDOMChar theChar)
XalanDOMString & operator+=(XalanDOMChar theChar)
int compare(size_type thePosition1, size_type theCount1, const XalanDOMChar *theString, size_type theCount2=size_type(npos)) const
void insert(iterator thePosition, size_type theCount, XalanDOMChar theChar)
XalanDOMString(size_type theCount, XalanDOMChar theChar, MemoryManager &theManager XALAN_DEFAULT_MEMMGR)
const_reference operator[](size_type theIndex) const
const XalanDOMChar & const_reference
XalanDOMString & append(const XalanDOMChar *theString)
XalanDOMString & assign(const XalanDOMChar *theSource)
XalanVector< XalanDOMChar > XalanDOMCharVectorType
void insert(iterator theInsertPosition, iterator theFirstPosition, iterator theLastPosition)
void reset(MemoryManager &theManager, const char *theString)
MemoryManager & getMemoryManager()
static size_type length(const XalanDOMChar *theString)
XalanDOMString & operator=(XalanDOMChar theRHS)
XalanDOMString & append(size_type theCount, XalanDOMChar theChar)
XalanVector< wchar_t > WideCharVectorType
void swap(XalanDOMString &theOther)
const_iterator begin() const
void resize(size_type theCount)
XalanDOMString & operator=(const XalanDOMChar *theRHS)
static bool equals(const XalanDOMChar *theLHS, const XalanDOMChar *theRHS)
static const size_type npos
XalanDOMCharVectorType::reverse_iterator reverse_iterator
const_iterator getIteratorForPosition(size_type thePosition) const
XalanDOMString & assign(const char *theSource, size_type theCount)
XalanDOMString & append(const XalanDOMChar *theString, size_type theCount)
XalanDOMString & assign(const char *theSource)
reference at(size_type theIndex)
XalanDOMCharVectorType::const_reverse_iterator const_reverse_iterator
reference operator[](size_type theIndex)
XalanDOMString & insert(size_type thePosition, const XalanDOMChar *theString, size_type theCount)
XalanDOMString * clone(MemoryManager &theManager)
int compare(const XalanDOMString &theString) const
static bool equals(const XalanDOMChar *theLHS, const XalanDOMString &theRHS)
void reset(MemoryManager &theManager, const XalanDOMChar *theString)
XalanDOMCharVectorType::const_iterator const_iterator
XalanDOMString(const XalanDOMString &theSource, MemoryManager &theManager XALAN_DEFAULT_CONSTRUCTOR_MEMMGR, size_type theStartPosition=0, size_type theCount=size_type(npos))
void resize(size_type theCount, XalanDOMChar theChar)
static MemoryManager & getDefaultXercesMemMgr()
const value_type * const_iterator
const_reverse_iterator_ const_reverse_iterator
reverse_iterator_ reverse_iterator
XalanVector< char > CharVectorType
XalanVector< XalanDOMChar > XalanDOMCharVectorType
TranscodeToLocalCodePage(const XalanDOMChar *theSourceString, XalanDOMString::size_type theSourceStringLength, CharVectorType &targetVector, bool terminate=false)
Convert a XalanDOMChar string to C++ standard library vector, transcoding to the default local code p...
const XalanDOMString TranscodeFromLocalCodePage(const char *theSourceString, XalanDOMString::size_type theSourceStringLength=XalanDOMString::npos)
Convert a string to a XalanDOMString, transcoding from the default local code page.
bool operator==(const XalanVector< Type > &theLHS, const XalanVector< Type > &theRHS)
bool operator!=(const XalanVector< Type > &theLHS, const XalanVector< Type > &theRHS)
Equals functor for DOMStrings.
Hash functor for DOMStrings.
Less than functor for DOMStrings.
Not equals functor for DOMStrings.
Equal to functor for DOMStrings.
Hash functor for DOMStrings.
Less than functor for DOMStrings.
DOMStringHashFunction Hasher
std::equal_to< XalanDOMString > Comparator
pointer_equal< XalanDOMString > Comparator
DOMStringPointerHashFunction Hasher
pointer_equal< XalanDOMString > Comparator
DOMStringPointerHashFunction Hasher