Interface ObjectChannel<T>

Type Parameters:
T - object type accepted by the channel.

@Contract(threading=SAFE) public interface ObjectChannel<T>
Abstract object stream channel.

Implementations are expected to be thread-safe.

Since:
5.5
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Terminates the underlying data stream and optionally writes a closing sequence.
    int
    write(T obj)
    Writes serialized object into the underlying data stream.
  • Method Details

    • write

      int write(T obj) throws IOException
      Writes serialized object into the underlying data stream.
      Parameters:
      obj - object
      Returns:
      The number of elements written, possibly zero
      Throws:
      IOException
    • endStream

      void endStream() throws IOException
      Terminates the underlying data stream and optionally writes a closing sequence.
      Throws:
      IOException