#include "unicode/utypes.h"
#if !UCONFIG_NO_COLLATION
#include "unicode/bytestream.h"
#include "collation.h"
#include "collationiterator.h"
#include "collationkeys.h"
#include "collationsettings.h"
#include "uassert.h"
U_NAMESPACE_BEGIN
SortKeyByteSink::~SortKeyByteSink() { … }
void
SortKeyByteSink::Append(const char *bytes, int32_t n) { … }
char *
SortKeyByteSink::GetAppendBuffer(int32_t min_capacity,
int32_t desired_capacity_hint,
char *scratch,
int32_t scratch_capacity,
int32_t *result_capacity) { … }
namespace {
class SortKeyLevel : public UMemory { … };
void SortKeyLevel::appendByte(uint32_t b) { … }
void
SortKeyLevel::appendWeight16(uint32_t w) { … }
void
SortKeyLevel::appendWeight32(uint32_t w) { … }
void
SortKeyLevel::appendReverseWeight16(uint32_t w) { … }
UBool SortKeyLevel::ensureCapacity(int32_t appendCapacity) { … }
}
CollationKeys::LevelCallback::~LevelCallback() { … }
UBool
CollationKeys::LevelCallback::needToWrite(Collation::Level ) { … }
static const uint32_t levelMasks[UCOL_STRENGTH_LIMIT] = …;
void
CollationKeys::writeSortKeyUpToQuaternary(CollationIterator &iter,
const UBool *compressibleBytes,
const CollationSettings &settings,
SortKeyByteSink &sink,
Collation::Level minLevel, LevelCallback &callback,
UBool preflight, UErrorCode &errorCode) { … }
U_NAMESPACE_END
#endif