Interface DataSink

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Interface Description
      static interface  DataSink.Factory
      Deprecated.
      A factory for DataSink instances.
    • Method Detail

      • open

        void open​(DataSpec dataSpec)
           throws IOException
        Deprecated.
        Opens the sink to consume the specified data.

        Note: If an IOException is thrown, callers must still call close() to ensure that any partial effects of the invocation are cleaned up.

        Parameters:
        dataSpec - Defines the data to be consumed.
        Throws:
        IOException - If an error occurs opening the sink.
      • write

        void write​(byte[] buffer,
                   int offset,
                   int length)
            throws IOException
        Deprecated.
        Consumes the provided data.
        Parameters:
        buffer - The buffer from which data should be consumed.
        offset - The offset of the data to consume in buffer.
        length - The length of the data to consume, in bytes.
        Throws:
        IOException - If an error occurs writing to the sink.