Class ReleasableBytesStreamOutput

  • All Implemented Interfaces:,, java.lang.AutoCloseable, Releasable

    public class ReleasableBytesStreamOutput
    extends BytesStreamOutput
    implements Releasable
    An bytes stream output that allows providing a BigArrays instance expecting it to require releasing its content (bytes()) once done.

    Please note, closing this stream will release the bytes that are in use by any ReleasablePagedBytesReference returned from bytes(), so this stream should only be closed after the bytes have been output or copied elsewhere.