Package org.elasticsearch.index.mapper
Class Uid
- java.lang.Object
-
- org.elasticsearch.index.mapper.Uid
-
public final class Uid extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static charDELIMITERstatic byteDELIMITER_BYTE
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static StringdecodeId(byte[] idBytes)Decode an indexed id back to its original form.static StringdecodeId(byte[] idBytes, int offset, int length)Decode an indexed id back to its original form.static BytesRefencodeId(String id)Encode an id for storage in the index.booleanequals(Object o)inthashCode()Stringid()StringtoString()Stringtype()
-
-
-
Field Detail
-
DELIMITER
public static final char DELIMITER
- See Also:
- Constant Field Values
-
DELIMITER_BYTE
public static final byte DELIMITER_BYTE
- See Also:
- Constant Field Values
-
-
Method Detail
-
type
public String type()
-
id
public String id()
-
encodeId
public static BytesRef encodeId(String id)
Encode an id for storage in the index. This encoding is optimized for numeric and base64 ids, which are encoded in a much denser way than what UTF8 would do.- See Also:
decodeId(byte[])
-
decodeId
public static String decodeId(byte[] idBytes)
Decode an indexed id back to its original form.- See Also:
encodeId(java.lang.String)
-
decodeId
public static String decodeId(byte[] idBytes, int offset, int length)
Decode an indexed id back to its original form.- See Also:
encodeId(java.lang.String)
-
-