Package org.eclipse.jetty.toolchain.test
Class ByteBufferUtils
java.lang.Object
org.eclipse.jetty.toolchain.test.ByteBufferUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]
toArray
(ByteBuffer buffer) Get the byte array out of a ByteBuffer.static String
toString
(ByteBuffer buffer) Convert the ByteBuffer to a UTF-8 String.
-
Constructor Details
-
ByteBufferUtils
public ByteBufferUtils()
-
-
Method Details
-
toArray
Get the byte array out of a ByteBuffer.- Parameters:
buffer
- the buffer to get the array from- Returns:
- the byte buffer array
-
toString
Convert the ByteBuffer to a UTF-8 String.- Parameters:
buffer
- the buffer to convert- Returns:
- the String form of the buffer
-