Required Instance Methodswift-nio 2.72.0NIOCore

    write(context:data:promise:)

    Called to request a write operation. The write operation will write the messages through the ChannelPipeline. Those are then ready to be flushed to the actual Channel when Channel.flush or ChannelHandlerContext.flush is called.

    ChannelHandler.swift:86
    func write(context: ChannelHandlerContext, data: NIOAny, promise: EventLoopPromise<Void>?)

    Parameters

    context

    The ChannelHandlerContext which this ChannelHandler belongs to.

    data

    The data to write through the Channel, wrapped in a NIOAny.

    promise

    The EventLoopPromise which should be notified once the operation completes, or nil if no notification should take place.

    This should call context.write to forward the operation to the next _ChannelOutboundHandler in the ChannelPipeline or complete the EventLoopPromise to let the caller know that the operation completed.

    Other requirements

    Instance members

    Citizens in NIOCore

    Default implementations