Package com.ibm.icu.impl
Class PropsVectors.DefaultGetFoldedValue
java.lang.Object
com.ibm.icu.impl.PropsVectors.DefaultGetFoldedValue
- All Implemented Interfaces:
TrieBuilder.DataManipulate
- Enclosing class:
PropsVectors
private static class PropsVectors.DefaultGetFoldedValue
extends Object
implements TrieBuilder.DataManipulate
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
getFoldedValue
(int start, int offset) Build-time trie callback function, used with serialize().
-
Field Details
-
builder
-
-
Constructor Details
-
DefaultGetFoldedValue
-
-
Method Details
-
getFoldedValue
public int getFoldedValue(int start, int offset) Description copied from interface:TrieBuilder.DataManipulate
Build-time trie callback function, used with serialize(). This function calculates a lead surrogate's value including a folding offset from the 1024 supplementary code points [start..start+1024[ . It is U+10000 invalid input: '<'= start invalid input: '<'= U+10fc00 and (startinvalid input: '&'0x3ff)==0. The folding offset is provided by the caller. It is offset=UTRIE_BMP_INDEX_LENGTH+n*UTRIE_SURROGATE_BLOCK_COUNT with n=0..1023. Instead of the offset itself, n can be stored in 10 bits - or fewer if it can be assumed that few lead surrogates have associated data. The returned value must be - not zero if and only if there is relevant data for the corresponding 1024 supplementary code points - such that UTrie.getFoldingOffset(UNewTrieGetFoldedValue(..., offset))==offset- Specified by:
getFoldedValue
in interfaceTrieBuilder.DataManipulate
- Returns:
- a folded value, or 0 if there is no relevant data for the lead surrogate.
-