org.apache.olingo.server.api

## Interface ODataContentWriteErrorCallback

-     public interface ODataContentWriteErrorCallback

  The ODataContentWriteErrorCallback is called when during the `ODataContent.write(OutputStream)` or the `ODataContent.write(WritableByteChannel)` an error occurs.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `handleError(ODataContentWriteErrorContext context, WritableByteChannel channel)` Is called when during write in the ODataContent an error occurs.

- - ### Method Detail

    - #### handleError

          void handleError(ODataContentWriteErrorContext context,
                           WritableByteChannel channel)

      Is called when during write in the ODataContent an error occurs. The `context:ODataContentWriteErrorContext` contains all relevant information and the `channel` is the channel (stream) in which before was written. This channel is at this point not closed and can be used to write additional information. ATTENTION: This channel MUST NOT be closed by the callback. It will be closed by the layer responsible for the environment / data transfer (e.g. application server).
      Parameters:
        `context` - contains all relevant error information
        `channel` - is the channel (stream) in which before was written

Copyright © 2013–2022 The Apache Software Foundation. All rights reserved.