Class ConnectionMetadata (0.17.0)
Stay organized with collections
Save and categorize content based on your preferences.
publicclass ConnectionMetadataimplementsAutoCloseableImplements
AutoCloseableInherited Members
Constructors
ConnectionMetadata(InputStream rawInputStream, OutputStream rawOutputStream)
publicConnectionMetadata(InputStreamrawInputStream,OutputStreamrawOutputStream)Creates a DataInputStream and a DataOutputStream from the given raw streams and pushes these as the current streams to use for communication for a connection.
Methods
close()
publicvoidclose()getInputStream()
publicDataInputStreamgetInputStream()Returns the current DataInputStream for the connection.
getOutputStream()
publicDataOutputStreamgetOutputStream()Returns the current DataOutputStream for the connection.
markForRestart()
publicvoidmarkForRestart()peekNextByte(long maxWaitMillis)
publiccharpeekNextByte(longmaxWaitMillis)Returns the next byte in the input stream without removing it. Returns zero if no bytes are available. This method will wait for up to maxWaitMillis milliseconds to allow pending data to become available in the buffer.