Class VirtualMachine.ForHotSpot.Connection.ForJnaWindowsNamedPipe.NamedPipeResponse
java.lang.Object
net.bytebuddy.agent.VirtualMachine.ForHotSpot.Connection.ForJnaWindowsNamedPipe.NamedPipeResponse
- All Implemented Interfaces:
Closeable, AutoCloseable, VirtualMachine.ForHotSpot.Connection.Response
- Enclosing class:
VirtualMachine.ForHotSpot.Connection.ForJnaWindowsNamedPipe
protected static class VirtualMachine.ForHotSpot.Connection.ForJnaWindowsNamedPipe.NamedPipeResponse
extends Object
implements VirtualMachine.ForHotSpot.Connection.Response
A response that is sent via a named pipe.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final com.sun.jna.platform.win32.WinNT.HANDLEA handle of the named pipe. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedNamedPipeResponse(com.sun.jna.platform.win32.WinNT.HANDLE pipe) Creates a new response via a named pipe. -
Method Summary
-
Field Details
-
pipe
private final com.sun.jna.platform.win32.WinNT.HANDLE pipeA handle of the named pipe.
-
-
Constructor Details
-
NamedPipeResponse
protected NamedPipeResponse(com.sun.jna.platform.win32.WinNT.HANDLE pipe) Creates a new response via a named pipe.- Parameters:
pipe- The handle of the named pipe.
-
-
Method Details
-
read
public int read(byte[] buffer) Reads a buffer from the target VM.- Specified by:
readin interfaceVirtualMachine.ForHotSpot.Connection.Response- Parameters:
buffer- The buffer to read to.- Returns:
- The bytes read or
-1if no more bytes could be read.
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-