/third_party/icu/icu4c/source/common/ |
D | unistr_case.cpp | 104 int32_t newLength; in caseMap() local 139 newLength = stringCaseMapper(caseLocale, options, UCASEMAP_BREAK_ITERATOR in caseMap() 143 setLength(newLength); in caseMap() 170 newLength = oldLength + edits.lengthDelta(); in caseMap() 171 if (newLength > oldLength && !cloneArrayIfNeeded(newLength, newLength)) { in caseMap() 176 replacementChars, ei.replacementIndex(), ei.newLength()); in caseMap() 184 newLength = oldLength + edits.lengthDelta(); in caseMap() 197 if (!cloneArrayIfNeeded(newLength, newLength, FALSE, &bufferToDelete, TRUE)) { in caseMap() 202 newLength = stringCaseMapper(caseLocale, options, UCASEMAP_BREAK_ITERATOR in caseMap() 209 setLength(newLength); in caseMap()
|
D | edits.cpp | 141 void Edits::addReplace(int32_t oldLength, int32_t newLength) { in addReplace() argument 143 if(oldLength < 0 || newLength < 0) { in addReplace() 147 if (oldLength == 0 && newLength == 0) { in addReplace() 151 int32_t newDelta = newLength - oldLength; in addReplace() 163 newLength <= MAX_SHORT_CHANGE_NEW_LENGTH) { in addReplace() 165 int32_t u = (oldLength << 12) | (newLength << 9); in addReplace() 178 if (oldLength < LENGTH_IN_1TRAIL && newLength < LENGTH_IN_1TRAIL) { in addReplace() 180 head |= newLength; in addReplace() 194 if(newLength < LENGTH_IN_1TRAIL) { in addReplace() 195 head |= newLength; in addReplace() [all …]
|
D | unistr.cpp | 357 int32_t getGrowCapacity(int32_t newLength) { in getGrowCapacity() argument 358 int32_t growSize = (newLength >> 2) + kGrowSize; in getGrowCapacity() 359 if(growSize <= (kMaxCapacity - newLength)) { in getGrowCapacity() 360 return newLength + growSize; in getGrowCapacity() 1168 int32_t newLength) in findAndReplace() argument 1176 newText.pinIndices(newStart, newLength); in findAndReplace() 1189 replace(pos, oldLength, newText, newStart, newLength); in findAndReplace() 1191 start = pos + newLength; in findAndReplace() 1465 int32_t newLength = oldLength - length; in doReplace() local 1466 if(srcLength > (INT32_MAX - newLength)) { in doReplace() [all …]
|
D | charstr.cpp | 78 CharString &CharString::truncate(int32_t newLength) { in truncate() argument 79 if(newLength<0) { in truncate() 80 newLength=0; in truncate() 82 if(newLength<len) { in truncate() 83 buffer[len=newLength]=0; in truncate()
|
/third_party/flutter/skia/third_party/externals/icu/source/common/ |
D | unistr_case.cpp | 104 int32_t newLength; in caseMap() local 139 newLength = stringCaseMapper(caseLocale, options, UCASEMAP_BREAK_ITERATOR in caseMap() 143 setLength(newLength); in caseMap() 170 newLength = oldLength + edits.lengthDelta(); in caseMap() 171 if (newLength > oldLength && !cloneArrayIfNeeded(newLength, newLength)) { in caseMap() 176 replacementChars, ei.replacementIndex(), ei.newLength()); in caseMap() 184 newLength = oldLength + edits.lengthDelta(); in caseMap() 197 if (!cloneArrayIfNeeded(newLength, newLength, FALSE, &bufferToDelete, TRUE)) { in caseMap() 202 newLength = stringCaseMapper(caseLocale, options, UCASEMAP_BREAK_ITERATOR in caseMap() 209 setLength(newLength); in caseMap()
|
D | edits.cpp | 141 void Edits::addReplace(int32_t oldLength, int32_t newLength) { in addReplace() argument 143 if(oldLength < 0 || newLength < 0) { in addReplace() 147 if (oldLength == 0 && newLength == 0) { in addReplace() 151 int32_t newDelta = newLength - oldLength; in addReplace() 163 newLength <= MAX_SHORT_CHANGE_NEW_LENGTH) { in addReplace() 165 int32_t u = (oldLength << 12) | (newLength << 9); in addReplace() 178 if (oldLength < LENGTH_IN_1TRAIL && newLength < LENGTH_IN_1TRAIL) { in addReplace() 180 head |= newLength; in addReplace() 194 if(newLength < LENGTH_IN_1TRAIL) { in addReplace() 195 head |= newLength; in addReplace() [all …]
|
D | unistr.cpp | 358 int32_t getGrowCapacity(int32_t newLength) { in getGrowCapacity() argument 359 int32_t growSize = (newLength >> 2) + kGrowSize; in getGrowCapacity() 360 if(growSize <= (kMaxCapacity - newLength)) { in getGrowCapacity() 361 return newLength + growSize; in getGrowCapacity() 1169 int32_t newLength) in findAndReplace() argument 1177 newText.pinIndices(newStart, newLength); in findAndReplace() 1190 replace(pos, oldLength, newText, newStart, newLength); in findAndReplace() 1192 start = pos + newLength; in findAndReplace() 1466 int32_t newLength = oldLength - length; in doReplace() local 1467 if(srcLength > (INT32_MAX - newLength)) { in doReplace() [all …]
|
D | charstr.cpp | 55 CharString &CharString::truncate(int32_t newLength) { in truncate() argument 56 if(newLength<0) { in truncate() 57 newLength=0; in truncate() 59 if(newLength<len) { in truncate() 60 buffer[len=newLength]=0; in truncate()
|
/third_party/skia/third_party/externals/icu/source/common/ |
D | unistr_case.cpp | 104 int32_t newLength; in caseMap() local 139 newLength = stringCaseMapper(caseLocale, options, UCASEMAP_BREAK_ITERATOR in caseMap() 143 setLength(newLength); in caseMap() 170 newLength = oldLength + edits.lengthDelta(); in caseMap() 171 if (newLength > oldLength && !cloneArrayIfNeeded(newLength, newLength)) { in caseMap() 176 replacementChars, ei.replacementIndex(), ei.newLength()); in caseMap() 184 newLength = oldLength + edits.lengthDelta(); in caseMap() 197 if (!cloneArrayIfNeeded(newLength, newLength, FALSE, &bufferToDelete, TRUE)) { in caseMap() 202 newLength = stringCaseMapper(caseLocale, options, UCASEMAP_BREAK_ITERATOR in caseMap() 209 setLength(newLength); in caseMap()
|
D | edits.cpp | 142 void Edits::addReplace(int32_t oldLength, int32_t newLength) { in addReplace() argument 144 if(oldLength < 0 || newLength < 0) { in addReplace() 148 if (oldLength == 0 && newLength == 0) { in addReplace() 152 int32_t newDelta = newLength - oldLength; in addReplace() 164 newLength <= MAX_SHORT_CHANGE_NEW_LENGTH) { in addReplace() 166 int32_t u = (oldLength << 12) | (newLength << 9); in addReplace() 179 if (oldLength < LENGTH_IN_1TRAIL && newLength < LENGTH_IN_1TRAIL) { in addReplace() 181 head |= newLength; in addReplace() 195 if(newLength < LENGTH_IN_1TRAIL) { in addReplace() 196 head |= newLength; in addReplace() [all …]
|
D | unistr.cpp | 357 int32_t getGrowCapacity(int32_t newLength) { in getGrowCapacity() argument 358 int32_t growSize = (newLength >> 2) + kGrowSize; in getGrowCapacity() 359 if(growSize <= (kMaxCapacity - newLength)) { in getGrowCapacity() 360 return newLength + growSize; in getGrowCapacity() 1168 int32_t newLength) in findAndReplace() argument 1176 newText.pinIndices(newStart, newLength); in findAndReplace() 1189 replace(pos, oldLength, newText, newStart, newLength); in findAndReplace() 1191 start = pos + newLength; in findAndReplace() 1465 int32_t newLength = oldLength - length; in doReplace() local 1466 if(srcLength > (INT32_MAX - newLength)) { in doReplace() [all …]
|
D | charstr.cpp | 94 CharString &CharString::truncate(int32_t newLength) { in truncate() argument 95 if(newLength<0) { in truncate() 96 newLength=0; in truncate() 98 if(newLength<len) { in truncate() 99 buffer[len=newLength]=0; in truncate()
|
/third_party/node/deps/icu-small/source/common/ |
D | unistr_case.cpp | 104 int32_t newLength; in caseMap() local 139 newLength = stringCaseMapper(caseLocale, options, UCASEMAP_BREAK_ITERATOR in caseMap() 143 setLength(newLength); in caseMap() 170 newLength = oldLength + edits.lengthDelta(); in caseMap() 171 if (newLength > oldLength && !cloneArrayIfNeeded(newLength, newLength)) { in caseMap() 176 replacementChars, ei.replacementIndex(), ei.newLength()); in caseMap() 184 newLength = oldLength + edits.lengthDelta(); in caseMap() 197 if (!cloneArrayIfNeeded(newLength, newLength, FALSE, &bufferToDelete, TRUE)) { in caseMap() 202 newLength = stringCaseMapper(caseLocale, options, UCASEMAP_BREAK_ITERATOR in caseMap() 209 setLength(newLength); in caseMap()
|
D | edits.cpp | 142 void Edits::addReplace(int32_t oldLength, int32_t newLength) { in addReplace() argument 144 if(oldLength < 0 || newLength < 0) { in addReplace() 148 if (oldLength == 0 && newLength == 0) { in addReplace() 152 int32_t newDelta = newLength - oldLength; in addReplace() 164 newLength <= MAX_SHORT_CHANGE_NEW_LENGTH) { in addReplace() 166 int32_t u = (oldLength << 12) | (newLength << 9); in addReplace() 179 if (oldLength < LENGTH_IN_1TRAIL && newLength < LENGTH_IN_1TRAIL) { in addReplace() 181 head |= newLength; in addReplace() 195 if(newLength < LENGTH_IN_1TRAIL) { in addReplace() 196 head |= newLength; in addReplace() [all …]
|
D | unistr.cpp | 357 int32_t getGrowCapacity(int32_t newLength) { in getGrowCapacity() argument 358 int32_t growSize = (newLength >> 2) + kGrowSize; in getGrowCapacity() 359 if(growSize <= (kMaxCapacity - newLength)) { in getGrowCapacity() 360 return newLength + growSize; in getGrowCapacity() 1168 int32_t newLength) in findAndReplace() argument 1176 newText.pinIndices(newStart, newLength); in findAndReplace() 1189 replace(pos, oldLength, newText, newStart, newLength); in findAndReplace() 1191 start = pos + newLength; in findAndReplace() 1465 int32_t newLength = oldLength - length; in doReplace() local 1466 if(srcLength > (INT32_MAX - newLength)) { in doReplace() [all …]
|
D | charstr.cpp | 94 CharString &CharString::truncate(int32_t newLength) { in truncate() argument 95 if(newLength<0) { in truncate() 96 newLength=0; in truncate() 98 if(newLength<len) { in truncate() 99 buffer[len=newLength]=0; in truncate()
|
/third_party/icu/ohos_icu4j/src/main/java/ohos/global/icu/util/ |
D | CharsTrieBuilder.java | 155 int newLength=charsLength+1; in write() local 156 ensureCapacity(newLength); in write() 157 charsLength=newLength; in write() 169 int newLength=charsLength+length; in write() local 170 ensureCapacity(newLength); in write() 171 charsLength=newLength; in write() 180 int newLength=charsLength+length; in write() local 181 ensureCapacity(newLength); in write() 182 charsLength=newLength; in write()
|
D | BytesTrieBuilder.java | 177 int newLength=bytesLength+1; in write() local 178 ensureCapacity(newLength); in write() 179 bytesLength=newLength; in write() 191 int newLength=bytesLength+length; in write() local 192 ensureCapacity(newLength); in write() 193 bytesLength=newLength; in write() 202 int newLength=bytesLength+length; in write() local 203 ensureCapacity(newLength); in write() 204 bytesLength=newLength; in write()
|
/third_party/icu/icu4c/source/test/intltest/ |
D | testutil.cpp | 76 return UnicodeString() + ei.oldLength() + u"->" + ei.newLength(); in printOneEdit() 78 return UnicodeString() + ei.oldLength() + u"=" + ei.newLength(); in printOneEdit() 96 int32_t prevDestIndex = destIndex - expected[i].newLength; in srcIndexFromDest() 123 int32_t prevDestIndex = destIndex - expected[i].newLength; in destIndexFromSrc() 185 test.assertEquals(msg + u":" + __LINE__, expect.newLength, ei1.newLength()); in checkEditsIter() 195 test.assertEquals(msg + u":" + __LINE__, expect.newLength, ei2.newLength()); in checkEditsIter() 207 if (expect.newLength > 0) { in checkEditsIter() 211 test.assertEquals(msg + u":" + __LINE__, expect.newLength, ei2.newLength()); in checkEditsIter() 224 expDestIndex += expect.newLength; in checkEditsIter() 226 expReplIndex += expect.newLength; in checkEditsIter() [all …]
|
D | winnmtst.cpp | 198 int newLength = GetCurrencyFormatW(lcid, 0, nBuffer, NULL, NULL, 0); in getWindowsFormat() local 200 buffer = NEW_ARRAY(wchar_t, newLength); in getWindowsFormat() 202 GetCurrencyFormatW(lcid, 0, nBuffer, NULL, buffer, newLength); in getWindowsFormat() 212 int newLength = GetNumberFormatW(lcid, 0, nBuffer, NULL, NULL, 0); in getWindowsFormat() local 214 buffer = NEW_ARRAY(wchar_t, newLength); in getWindowsFormat() 216 GetNumberFormatW(lcid, 0, nBuffer, NULL, buffer, newLength); in getWindowsFormat()
|
/third_party/icu/ohos_icu4j/src/main/java/ohos/global/icu/text/ |
D | Edits.java | 139 public void addReplace(int oldLength, int newLength) { in addReplace() argument 140 if(oldLength < 0 || newLength < 0) { in addReplace() 142 "addReplace(" + oldLength + ", " + newLength + in addReplace() 145 if (oldLength == 0 && newLength == 0) { in addReplace() 149 int newDelta = newLength - oldLength; in addReplace() 160 newLength <= MAX_SHORT_CHANGE_NEW_LENGTH) { in addReplace() 162 int u = (oldLength << 12) | (newLength << 9); in addReplace() 175 if (oldLength < LENGTH_IN_1TRAIL && newLength < LENGTH_IN_1TRAIL) { in addReplace() 177 head |= newLength; in addReplace() 191 if(newLength < LENGTH_IN_1TRAIL) { in addReplace() [all …]
|
/third_party/flutter/engine/flutter/lib/web_ui/lib/src/engine/services/ |
D | buffers.dart | 46 set length(int newLength) { 47 if (newLength < _length) { 49 for (int i = newLength; i < _length; i++) { 52 } else if (newLength > _buffer.length) { 55 newBuffer = _createBuffer(newLength); 57 newBuffer = _createBiggerBuffer(newLength); 62 _length = newLength; 224 final int newLength = _length + valuesLength; 225 _ensureCapacity(newLength); 230 _length = newLength; [all …]
|
/third_party/icu/ohos_icu4j/src/main/tests/ohos/global/icu/dev/test/lang/ |
D | UCharacterCaseTest.java | 812 private int oldLength, newLength; field in UCharacterCaseTest.EditChange 813 EditChange(boolean change, int oldLength, int newLength) { in EditChange() argument 816 this.newLength = newLength; in EditChange() 822 return "" + ei.oldLength() + "->" + ei.newLength(); in printOneEdit() 824 return "" + ei.oldLength() + "=" + ei.newLength(); in printOneEdit() 842 int prevDestIndex = destIndex - expected[i].newLength; in srcIndexFromDest() 869 int prevDestIndex = destIndex - expected[i].newLength; in destIndexFromSrc() 918 assertEquals(msg, expect.newLength, ei1.newLength()); in checkEditsIter() 928 assertEquals(msg, expect.newLength, ei2.newLength()); in checkEditsIter() 940 if (expect.newLength > 0) { in checkEditsIter() [all …]
|
/third_party/node/deps/icu-small/source/i18n/ |
D | winnmfmt.cpp | 415 … int newLength = GetCurrencyFormatEx(localeName, 0, nBuffer, &formatInfo.currency, NULL, 0); in format() local 417 buffer = NEW_ARRAY(wchar_t, newLength); in format() 419 … GetCurrencyFormatEx(localeName, 0, nBuffer, &formatInfo.currency, buffer, newLength); in format() 435 … int newLength = GetNumberFormatEx(localeName, 0, nBuffer, &formatInfo.number, NULL, 0); in format() local 437 buffer = NEW_ARRAY(wchar_t, newLength); in format() 439 GetNumberFormatEx(localeName, 0, nBuffer, &formatInfo.number, buffer, newLength); in format()
|
/third_party/icu/icu4c/source/i18n/ |
D | winnmfmt.cpp | 414 … int newLength = GetCurrencyFormatEx(localeName, 0, nBuffer, &formatInfo.currency, NULL, 0); in format() local 416 buffer = NEW_ARRAY(wchar_t, newLength); in format() 418 … GetCurrencyFormatEx(localeName, 0, nBuffer, &formatInfo.currency, buffer, newLength); in format() 434 … int newLength = GetNumberFormatEx(localeName, 0, nBuffer, &formatInfo.number, NULL, 0); in format() local 436 buffer = NEW_ARRAY(wchar_t, newLength); in format() 438 GetNumberFormatEx(localeName, 0, nBuffer, &formatInfo.number, buffer, newLength); in format()
|