Package org.apache.hadoop.hbase.util
Class TestOrderedBytes
java.lang.Object
org.apache.hadoop.hbase.util.TestOrderedBytes
-
Field Summary
Modifier and TypeFieldDescription(package private) static final int[]
(package private) static final BigDecimal[]
static final HBaseClassTestRule
(package private) static final int[]
(package private) static final Double[]
(package private) static final int[]
(package private) static final Long[]
(package private) static final double
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Test BlobCopy encoding.void
Assert invalid input byte[] are rejected by BlobCopyvoid
Test BlobVar encoding.void
Test length estimation algorithms for BlobVar encoding.void
Test if the data encoded by our encoding function can be decoded correctly.void
Test encoded value checkvoid
Test float32 encoding.void
Test float64 encoding.void
Test int16 encoding.void
Test int32 encoding.void
Test int64 encoding.void
testInt8()
Test int8 encoding.void
Test integer encoding.void
Verify Real and Int encodings are compatible.void
Fill gaps in Numeric encoding testing.void
Test real encoding.void
testSkip()
Test generic skip logicvoid
Test string encoding.void
void
Tests the variable uint64 encoding.void
Expected lengths of equivalent values should match
-
Field Details
-
CLASS_RULE
-
I_VALS
-
I_LENGTHS
-
D_VALS
-
D_LENGTHS
-
BD_VALS
-
BD_LENGTHS
-
MIN_EPSILON
- See Also:
-
-
Constructor Details
-
TestOrderedBytes
public TestOrderedBytes()
-
-
Method Details
-
testVerifyTestIntegrity
Expected lengths of equivalent values should match -
testVaruint64Boundaries
Tests the variable uint64 encoding.Building sqlite4 with -DVARINT_TOOL provides this reference:
$ ./varint_tool 240 2287 67823 16777215 4294967295 1099511627775 281474976710655 72057594037927935 18446744073709551615
240 = f0
2287 = f8ff
67823 = f9ffff
16777215 = faffffff
4294967295 = fbffffffff
1099511627775 = fcffffffffff
281474976710655 = fdffffffffffff
72057594037927935 = feffffffffffffff
9223372036854775807 = ff7fffffffffffffff (Long.MAX_VAL)
9223372036854775808 = ff8000000000000000 (Long.MIN_VAL)
18446744073709551615 = ffffffffffffffffff -
testNumericInt
Test integer encoding. Example input values come from reference wiki page. -
testNumericReal
Test real encoding. Example input values come from reference wiki page. -
testNumericOther
Fill gaps in Numeric encoding testing. -
testNumericIntRealCompatibility
Verify Real and Int encodings are compatible. -
testInt8
Test int8 encoding. -
testInt16
Test int16 encoding. -
testInt32
Test int32 encoding. -
testInt64
Test int64 encoding. -
testFloat32
Test float32 encoding. -
testFloat64
Test float64 encoding. -
testString
Test string encoding. -
testStringNoNullChars
-
testBlobVarLencodedLength
Test length estimation algorithms for BlobVar encoding. Does not cover 0-length input case properly. -
testBlobVar
Test BlobVar encoding. -
testBlobCopy
Test BlobCopy encoding. -
testBlobCopyNoZeroBytes
Assert invalid input byte[] are rejected by BlobCopy -
testSkip
Test generic skip logic -
testEncodedValueCheck
Test encoded value check -
testEncodeDecodeMatch
Test if the data encoded by our encoding function can be decoded correctly.
-