galaxy.io
Class GalaxyOutputStream
java.lang.Object
|
+--galaxy.io.GalaxyOutputStream
- public class GalaxyOutputStream
- extends java.lang.Object
This class provides methods for writing data to a Galaxy Communicator
connection.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GalaxyOutputStream
public GalaxyOutputStream(java.io.OutputStream out)
throws java.io.IOException
- Constructor
- Parameters:
out
- the output stream to use
close
public void close()
throws java.io.IOException
writeMessage
public void writeMessage(GalaxyMessage msg)
throws java.io.IOException
- Writes a message to the output stream.
- Parameters:
msg
- the message- Throws:
java.io.IOException
- If there is an error writing to the output stream
writeEOT
public void writeEOT(DisconnectMessage msg)
throws java.io.IOException
- Writes a disconnect message to the output stream.
- Parameters:
msg
- the disconnect message- Throws:
java.io.IOException
- If there is an error writing to the output stream
writeObject
public void writeObject(java.lang.Object obj,
int msgType)
throws java.io.IOException
- Writes an object to the output stream.
- Parameters:
obj
- the objectmsgType
- the message type (object is encapsulated in a message)- Throws:
java.io.IOException
- If there is an error writing to the output stream