io.flutter.plugin.common

## Interface EventChannel.EventSink

- Enclosing class:
    EventChannel

      public static interface EventChannel.EventSink

  Event callback. Supports dual use: Producers of events to be sent to Flutter act as clients of this interface for sending events. Consumers of events sent from Flutter implement this interface for handling received events (the latter facility has not been implemented yet).

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `endOfStream()` Consumes end of stream.
    `void` | `error(String errorCode, String errorMessage, Object errorDetails)` Consumes an error event.
    `void` | `success(Object event)` Consumes a successful event.

- - ### Method Detail

    - #### success

          void success(Object event)

      Consumes a successful event.
      Parameters:
        `event` - the event, possibly null.

    - #### error

          void error(String errorCode,
                     String errorMessage,
                     Object errorDetails)

      Consumes an error event.
      Parameters:
        `errorCode` - an error code String.
        `errorMessage` - a human-readable error message String, possibly null.
        `errorDetails` - error details, possibly null

    - #### endOfStream

          void endOfStream()

      Consumes end of stream. Ensuing calls to `success(Object)` or `error(String, String, Object)`, if any, are ignored.