|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.libvirt.Stream
public class Stream
Field Summary | |
---|---|
protected Libvirt |
libvirt
The libvirt connection from the hypervisor |
static int |
VIR_STREAM_NONBLOCK
|
Method Summary | |
---|---|
int |
abort()
Request that the in progress data transfer be cancelled abnormally before the end of the stream has been reached |
int |
addCallback(int events,
Libvirt.VirStreamEventCallback cb)
Register a callback to be notified when a stream becomes writable, or readable. |
void |
finalize()
|
int |
finish()
Indicate that there is no further data is to be transmitted on the stream. |
int |
free()
Decrement the reference count on a stream, releasing the stream object if the reference count has hit zero. |
protected void |
processError()
Error handling logic to throw errors. |
int |
receive(byte[] data)
Receieves data from teh stream into the buffer provided. |
int |
receiveAll(Libvirt.VirStreamSinkFunc handler)
Batch receive method |
int |
removeCallback()
Remove an event callback from the stream |
int |
send(java.lang.String data)
Write a series of bytes to the stream. |
int |
sendAll(Libvirt.VirStreamSourceFunc handler)
Batch send method |
int |
updateCallback(int events)
Changes the set of events to monitor for a stream. |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static int VIR_STREAM_NONBLOCK
protected Libvirt libvirt
Method Detail |
---|
public int abort() throws LibvirtException
LibvirtException
public int addCallback(int events, Libvirt.VirStreamEventCallback cb) throws LibvirtException
events
- the events to monitorcb
- the callback method
LibvirtException
public void finalize() throws LibvirtException
finalize
in class java.lang.Object
LibvirtException
public int finish() throws LibvirtException
LibvirtException
public int free() throws LibvirtException
LibvirtException
protected void processError() throws LibvirtException
LibvirtException
public int receive(byte[] data) throws LibvirtException
data
- the put the sata into
LibvirtException
public int receiveAll(Libvirt.VirStreamSinkFunc handler) throws LibvirtException
handler
- the callback handler
LibvirtException
http://www.libvirt.org/html/libvirt-libvirt.html#virStreamRecvAll
public int removeCallback() throws LibvirtException
LibvirtException
public int send(java.lang.String data) throws LibvirtException
data
- the data to write
LibvirtException
public int sendAll(Libvirt.VirStreamSourceFunc handler) throws LibvirtException
handler
- the callback handler
LibvirtException
public int updateCallback(int events) throws LibvirtException
events
- the events to monitor
LibvirtException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |