testGetBytesByteBuffer2() — netty Function Reference
Architecture documentation for the testGetBytesByteBuffer2() function in UnpooledTest.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 92a9cc6d_c97b_e7e3_f6b6_4ef2495270a8["testGetBytesByteBuffer2()"] 57588d83_f329_0d85_cfc5_eea9b8d43e8f["UnpooledTest"] 92a9cc6d_c97b_e7e3_f6b6_4ef2495270a8 -->|defined in| 57588d83_f329_0d85_cfc5_eea9b8d43e8f style 92a9cc6d_c97b_e7e3_f6b6_4ef2495270a8 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
buffer/src/test/java/io/netty/buffer/UnpooledTest.java lines 755–771
@Test
public void testGetBytesByteBuffer2() {
byte[] bytes = {'a', 'b', 'c', 'd', 'e', 'f', 'g'};
// Ensure destination buffer is bigger then what is wrapped in the ByteBuf.
final ByteBuffer nioBuffer = ByteBuffer.allocate(bytes.length + 1);
final ByteBuf wrappedBuffer = wrappedBuffer(bytes, 0, bytes.length);
try {
assertThrows(IndexOutOfBoundsException.class, new Executable() {
@Override
public void execute() throws Throwable {
wrappedBuffer.getBytes(wrappedBuffer.readerIndex(), nioBuffer);
}
});
} finally {
wrappedBuffer.release();
}
}
Domain
Subdomains
Source
Frequently Asked Questions
What does testGetBytesByteBuffer2() do?
testGetBytesByteBuffer2() is a function in the netty codebase, defined in buffer/src/test/java/io/netty/buffer/UnpooledTest.java.
Where is testGetBytesByteBuffer2() defined?
testGetBytesByteBuffer2() is defined in buffer/src/test/java/io/netty/buffer/UnpooledTest.java at line 755.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free