Bug 1737107 - Add documentation for Collator::GetSortKey. r=platform-i18n-reviewers,anba,dminor

Differential Revision: https://phabricator.services.mozilla.com/D129177
This commit is contained in:
Yoshi Cheng-Hao Huang 2021-10-25 18:24:07 +00:00
Родитель 817bdf1566
Коммит 4d0b49fcd3
1 изменённых файлов: 9 добавлений и 0 удалений

Просмотреть файл

@ -38,6 +38,15 @@ class Collator final {
~Collator();
/**
* Get a sort key with the provided UTF-16 string, and store the sort key into
* the provided buffer of byte array.
* Every sort key ends with 0x00, and the terminating 0x00 byte is counted
* when calculating the length of buffer. For the purpose of other byte
* values, check the "Special Byte Values" document from ICU.
*
* https://icu.unicode.org/design/collation/bytes
*/
template <typename B>
ICUResult GetSortKey(Span<const char16_t> aString, B& aBuffer) const {
return FillBufferWithICUCall(