org.apache.hadoop.hbase.util.vint
Class UVLongTool
java.lang.Object
org.apache.hadoop.hbase.util.vint.UVLongTool
@InterfaceAudience.Private
public class UVLongTool
- extends Object
Simple Variable Length Integer encoding. Left bit of 0 means we are on the last byte. If left
bit of the current byte is 1, then there is at least one more byte.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BYTE_7_RIGHT_BITS_SET
public static final byte BYTE_7_RIGHT_BITS_SET
- See Also:
- Constant Field Values
BYTE_LEFT_BIT_SET
public static final byte BYTE_LEFT_BIT_SET
- See Also:
- Constant Field Values
LONG_7_RIGHT_BITS_SET
public static final long LONG_7_RIGHT_BITS_SET
- See Also:
- Constant Field Values
LONG_8TH_BIT_SET
public static final long LONG_8TH_BIT_SET
- See Also:
- Constant Field Values
MAX_VALUE_BYTES
public static final byte[] MAX_VALUE_BYTES
UVLongTool
public UVLongTool()
numBytes
public static int numBytes(long in)
- long -> bytes
getBytes
public static byte[] getBytes(long value)
writeBytes
public static int writeBytes(long value,
OutputStream os)
throws IOException
- Throws:
IOException
getLong
public static long getLong(byte[] bytes)
- bytes -> long
getLong
public static long getLong(byte[] bytes,
int offset)
getLong
public static long getLong(InputStream is)
throws IOException
- Throws:
IOException
Copyright © 2007-2016 The Apache Software Foundation. All Rights Reserved.