summaryrefslogtreecommitdiffstats
path: root/mimelib/dwstring.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
commit4c6f8d69e2d1501837affb472c4eb8fec4462240 (patch)
tree766a8ad7939fcf3eec534184c36bd0e0f80489e2 /mimelib/dwstring.cpp
parent469cc56a805bd3d6940d54adbef554877c29853c (diff)
downloadtdepim-4c6f8d69e2d1501837affb472c4eb8fec4462240.tar.gz
tdepim-4c6f8d69e2d1501837affb472c4eb8fec4462240.zip
rename the following methods:
tqfind find tqreplace replace tqcontains contains git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'mimelib/dwstring.cpp')
-rw-r--r--mimelib/dwstring.cpp86
1 files changed, 43 insertions, 43 deletions
diff --git a/mimelib/dwstring.cpp b/mimelib/dwstring.cpp
index b8686e417..9a46bfa8b 100644
--- a/mimelib/dwstring.cpp
+++ b/mimelib/dwstring.cpp
@@ -365,7 +365,7 @@ DwString::DwString(const char* aBuf, size_t aLen)
mRep = new_rep_reference(sEmptyRep);
mStart = 0;
mLength = 0;
- _tqreplace(0, mLength, aBuf, aLen);
+ _replace(0, mLength, aBuf, aLen);
}
@@ -400,7 +400,7 @@ DwString::DwString(const char* aCstr)
mLength = 0;
if ( aCstr ) {
size_t len = strlen(aCstr);
- _tqreplace(0, mLength, aCstr, len);
+ _replace(0, mLength, aCstr, len);
}
}
@@ -418,7 +418,7 @@ DwString::DwString(size_t aLen, char aChar)
mRep = new_rep_reference(sEmptyRep);
mStart = 0;
mLength = 0;
- _tqreplace(0, mLength, aLen, aChar);
+ _replace(0, mLength, aLen, aChar);
}
@@ -476,7 +476,7 @@ void DwString::resize(size_t aLen, char aChar)
}
// expanding string
else if (aLen > mLength) {
- _tqreplace(mLength, 0, aLen-mLength, aChar);
+ _replace(mLength, 0, aLen-mLength, aChar);
}
}
@@ -534,10 +534,10 @@ DwString& DwString::append(const DwString& aStr, size_t aPos,
size_t len = DW_MIN(aLen, aStr.mLength - pos);
if (&aStr == this) {
DwString temp(aStr);
- _tqreplace(mLength, 0, &temp.mRep->mBuffer[temp.mStart+pos], len);
+ _replace(mLength, 0, &temp.mRep->mBuffer[temp.mStart+pos], len);
}
else {
- _tqreplace(mLength, 0, &aStr.mRep->mBuffer[aStr.mStart+pos], len);
+ _replace(mLength, 0, &aStr.mRep->mBuffer[aStr.mStart+pos], len);
}
return *this;
}
@@ -547,7 +547,7 @@ DwString& DwString::append(const char* aBuf, size_t aLen)
{
assert(aBuf != 0);
if (aBuf != 0) {
- _tqreplace(mLength, 0, aBuf, aLen);
+ _replace(mLength, 0, aBuf, aLen);
}
return *this;
}
@@ -557,14 +557,14 @@ DwString& DwString::append(const char* aCstr)
{
assert(aCstr != 0);
size_t len = (aCstr) ? strlen(aCstr) : 0;
- _tqreplace(mLength, 0, aCstr, len);
+ _replace(mLength, 0, aCstr, len);
return *this;
}
DwString& DwString::append(size_t aLen, char aChar)
{
- _tqreplace(mLength, 0, aLen, aChar);
+ _replace(mLength, 0, aLen, aChar);
return *this;
}
@@ -601,7 +601,7 @@ DwString& DwString::assign(const char* aBuf, size_t aLen)
{
assert(aBuf != 0);
assert(aLen != (size_t)-1);
- _tqreplace(0, mLength, aBuf, aLen);
+ _replace(0, mLength, aBuf, aLen);
return *this;
}
@@ -610,7 +610,7 @@ DwString& DwString::assign(const char* aCstr)
{
assert(aCstr != 0);
size_t len = (aCstr) ? strlen(aCstr) : 0;
- _tqreplace(0, mLength, aCstr, len);
+ _replace(0, mLength, aCstr, len);
return *this;
}
@@ -618,7 +618,7 @@ DwString& DwString::assign(const char* aCstr)
DwString& DwString::assign(size_t aLen, char aChar)
{
assert(aLen != (size_t)-1);
- _tqreplace(0, mLength, aLen, aChar);
+ _replace(0, mLength, aLen, aChar);
return *this;
}
@@ -638,10 +638,10 @@ DwString& DwString::insert(size_t aPos1, const DwString& aStr,
size_t len2 = DW_MIN(aLen2, aStr.mLength - pos2);
if (&aStr == this) {
DwString temp(aStr);
- _tqreplace(aPos1, 0, &temp.mRep->mBuffer[temp.mStart+pos2], len2);
+ _replace(aPos1, 0, &temp.mRep->mBuffer[temp.mStart+pos2], len2);
}
else {
- _tqreplace(aPos1, 0, &aStr.mRep->mBuffer[aStr.mStart+pos2], len2);
+ _replace(aPos1, 0, &aStr.mRep->mBuffer[aStr.mStart+pos2], len2);
}
return *this;
}
@@ -650,7 +650,7 @@ DwString& DwString::insert(size_t aPos1, const DwString& aStr,
DwString& DwString::insert(size_t aPos, const char* aBuf, size_t aLen)
{
assert(aBuf != 0);
- _tqreplace(aPos, 0, aBuf, aLen);
+ _replace(aPos, 0, aBuf, aLen);
return *this;
}
@@ -659,14 +659,14 @@ DwString& DwString::insert(size_t aPos, const char* aCstr)
{
assert(aCstr != 0);
size_t len = (aCstr) ? strlen(aCstr) : 0;
- _tqreplace(aPos, 0, aCstr, len);
+ _replace(aPos, 0, aCstr, len);
return *this;
}
DwString& DwString::insert(size_t aPos, size_t aLen, char aChar)
{
- _tqreplace(aPos, 0, aLen, aChar);
+ _replace(aPos, 0, aLen, aChar);
return *this;
}
@@ -676,18 +676,18 @@ DwString& DwString::erase(size_t aPos, size_t aLen)
assert(aPos <= mLength);
size_t pos = DW_MIN(aPos, mLength);
size_t len = DW_MIN(aLen, mLength - pos);
- _tqreplace(pos, len, "", 0);
+ _replace(pos, len, "", 0);
return *this;
}
-DwString& DwString::tqreplace(size_t aPos1, size_t aLen1, const DwString& aStr)
+DwString& DwString::replace(size_t aPos1, size_t aLen1, const DwString& aStr)
{
- return tqreplace(aPos1, aLen1, aStr, 0, aStr.mLength);
+ return replace(aPos1, aLen1, aStr, 0, aStr.mLength);
}
-DwString& DwString::tqreplace(size_t aPos1, size_t aLen1, const DwString& aStr,
+DwString& DwString::replace(size_t aPos1, size_t aLen1, const DwString& aStr,
size_t aPos2, size_t aLen2)
{
assert(aPos2 <= aStr.mLength);
@@ -695,35 +695,35 @@ DwString& DwString::tqreplace(size_t aPos1, size_t aLen1, const DwString& aStr,
size_t len2 = DW_MIN(aLen2, aStr.mLength - pos2);
if (&aStr == this) {
DwString temp(aStr);
- _tqreplace(aPos1, aLen1, &temp.mRep->mBuffer[temp.mStart+pos2], len2);
+ _replace(aPos1, aLen1, &temp.mRep->mBuffer[temp.mStart+pos2], len2);
}
else {
- _tqreplace(aPos1, aLen1, &aStr.mRep->mBuffer[aStr.mStart+pos2], len2);
+ _replace(aPos1, aLen1, &aStr.mRep->mBuffer[aStr.mStart+pos2], len2);
}
return *this;
}
-DwString& DwString::tqreplace(size_t aPos1, size_t aLen1, const char* aBuf,
+DwString& DwString::replace(size_t aPos1, size_t aLen1, const char* aBuf,
size_t aLen2)
{
- _tqreplace(aPos1, aLen1, aBuf, aLen2);
+ _replace(aPos1, aLen1, aBuf, aLen2);
return *this;
}
-DwString& DwString::tqreplace(size_t aPos1, size_t aLen1, const char* aCstr)
+DwString& DwString::replace(size_t aPos1, size_t aLen1, const char* aCstr)
{
size_t len2 = (aCstr) ? strlen(aCstr) : 0;
- _tqreplace(aPos1, aLen1, aCstr, len2);
+ _replace(aPos1, aLen1, aCstr, len2);
return *this;
}
-DwString& DwString::tqreplace(size_t aPos1, size_t aLen1, size_t aLen2,
+DwString& DwString::replace(size_t aPos1, size_t aLen1, size_t aLen2,
char aChar)
{
- _tqreplace(aPos1, aLen1, aLen2, aChar);
+ _replace(aPos1, aLen1, aLen2, aChar);
return *this;
}
@@ -755,13 +755,13 @@ void DwString::swap(DwString& aStr)
}
-size_t DwString::tqfind(const DwString& aStr, size_t aPos) const
+size_t DwString::find(const DwString& aStr, size_t aPos) const
{
- return tqfind(&aStr.mRep->mBuffer[aStr.mStart], aPos, aStr.mLength);
+ return find(&aStr.mRep->mBuffer[aStr.mStart], aPos, aStr.mLength);
}
-size_t DwString::tqfind(const char* aBuf, size_t aPos, size_t aLen) const
+size_t DwString::find(const char* aBuf, size_t aPos, size_t aLen) const
{
assert(aBuf != 0);
if (aBuf == 0) return (size_t)-1;
@@ -781,16 +781,16 @@ size_t DwString::tqfind(const char* aBuf, size_t aPos, size_t aLen) const
}
-size_t DwString::tqfind(const char* aCstr, size_t aPos) const
+size_t DwString::find(const char* aCstr, size_t aPos) const
{
assert(aCstr != 0);
if (aCstr == 0) return (size_t)-1;
size_t len = strlen(aCstr);
- return tqfind(aCstr, aPos, len);
+ return find(aCstr, aPos, len);
}
-size_t DwString::tqfind(char aChar, size_t aPos) const
+size_t DwString::find(char aChar, size_t aPos) const
{
if (aPos >= mLength) return (size_t)-1;
const char* buf = mRep->mBuffer + mStart;
@@ -801,13 +801,13 @@ size_t DwString::tqfind(char aChar, size_t aPos) const
}
-size_t DwString::rtqfind(const DwString& aStr, size_t aPos) const
+size_t DwString::rfind(const DwString& aStr, size_t aPos) const
{
- return rtqfind(&aStr.mRep->mBuffer[aStr.mStart], aPos, aStr.mLength);
+ return rfind(&aStr.mRep->mBuffer[aStr.mStart], aPos, aStr.mLength);
}
-size_t DwString::rtqfind(const char* aBuf, size_t aPos, size_t aLen) const
+size_t DwString::rfind(const char* aBuf, size_t aPos, size_t aLen) const
{
assert(aBuf != 0);
if (aBuf == 0) return (size_t)-1;
@@ -827,15 +827,15 @@ size_t DwString::rtqfind(const char* aBuf, size_t aPos, size_t aLen) const
}
-size_t DwString::rtqfind(const char* aCstr, size_t aPos) const
+size_t DwString::rfind(const char* aCstr, size_t aPos) const
{
assert(aCstr != 0);
size_t len = (aCstr) ? strlen(aCstr) : 0;
- return rtqfind(aCstr, aPos, len);
+ return rfind(aCstr, aPos, len);
}
-size_t DwString::rtqfind(char aChar, size_t aPos) const
+size_t DwString::rfind(char aChar, size_t aPos) const
{
size_t pos = DW_MIN(aPos, mLength - 1);
const char* buf = mRep->mBuffer + mStart;
@@ -1246,7 +1246,7 @@ void DwString::_copy()
}
-void DwString::_tqreplace(size_t aPos1, size_t aLen1, const char* aBuf, size_t aLen2)
+void DwString::_replace(size_t aPos1, size_t aLen1, const char* aBuf, size_t aLen2)
{
assert(aPos1 <= mLength);
assert(aBuf != 0);
@@ -1338,7 +1338,7 @@ void DwString::_tqreplace(size_t aPos1, size_t aLen1, const char* aBuf, size_t a
}
-void DwString::_tqreplace(size_t aPos1, size_t aLen1, size_t aLen2, char aChar)
+void DwString::_replace(size_t aPos1, size_t aLen1, size_t aLen2, char aChar)
{
assert(aPos1 <= mLength);
size_t pos1 = DW_MIN(aPos1, mLength);