public class TestByteBufferUtils extends Object
| Modifier and Type | Field and Description |
|---|---|
static HBaseClassTestRule |
CLASS_RULE |
| Constructor and Description |
|---|
TestByteBufferUtils(boolean useUnsafeIfPossible) |
| Modifier and Type | Method and Description |
|---|---|
static void |
afterClass() |
static Collection<Object[]> |
parameters() |
void |
setUp()
Create an array with sample data.
|
void |
testArePartEqual()
Test if we are comparing equal bytes.
|
void |
testCompareTo() |
void |
testCompressedInt()
Test 7-bit encoding of integers.
|
void |
testConsistencyWithHadoopVLong() |
void |
testCopyFromArrayToBuffer() |
void |
testCopyFromBuffer()
Test copying from buffer.
|
void |
testCopyFromBufferToArray() |
void |
testCopyFromSrcToDestWithThreads() |
void |
testCopyFromStream()
Test copying data from stream.
|
void |
testCopyToStreamWithOffset()
Test copying to stream from buffer with offset.
|
void |
testEquals() |
void |
testIntFitsIn()
Test how much bytes we need to store integer.
|
void |
testLongFitsIn()
Test how much bytes we need to store long.
|
void |
testMoveBufferToStream()
Test copying to stream from buffer.
|
void |
testPutInt()
Test serializing int to bytes
|
void |
testReadWriteVLong() |
void |
testRelativeCopyFromBuffertoBuffer() |
void |
testToBytes() |
void |
testToPrimitiveTypes() |
public static final HBaseClassTestRule CLASS_RULE
public TestByteBufferUtils(boolean useUnsafeIfPossible) throws Exception
Exceptionpublic static void afterClass() throws Exception
Exceptionpublic static Collection<Object[]> parameters()
public void setUp()
public void testReadWriteVLong()
public void testConsistencyWithHadoopVLong() throws IOException
IOExceptionpublic void testMoveBufferToStream()
public void testCopyToStreamWithOffset() throws IOException
IOException - On test failure.public void testCopyFromStream() throws IOException
IOException - On test failure.public void testCopyFromBuffer()
public void testCompressedInt() throws IOException
IOException - On test failure.public void testIntFitsIn()
public void testLongFitsIn()
public void testArePartEqual()
public void testPutInt()
public void testToBytes()
public void testToPrimitiveTypes()
public void testCopyFromArrayToBuffer()
public void testCopyFromSrcToDestWithThreads() throws InterruptedException
InterruptedExceptionpublic void testCopyFromBufferToArray()
public void testRelativeCopyFromBuffertoBuffer()
public void testCompareTo()
public void testEquals()
Copyright © 2007–2019 Cloudera. All rights reserved.