Example usage for io.netty.channel PendingWriteQueue PendingWriteQueue

List of usage examples for io.netty.channel PendingWriteQueue PendingWriteQueue

Introduction

In this page you can find the example usage for io.netty.channel PendingWriteQueue PendingWriteQueue.

Prototype

public PendingWriteQueue(ChannelHandlerContext ctx) 

Source Link

Usage

From source file:divconq.net.ssl.SslHandler.java

License:Apache License

@Override
public void handlerAdded(final ChannelHandlerContext ctx) throws Exception {
    this.ctx = ctx;
    pendingUnencryptedWrites = new PendingWriteQueue(ctx);

    if (ctx.channel().isActive() && engine.getUseClientMode()) {
        // channelActive() event has been fired already, which means this.channelActive() will
        // not be invoked. We have to initialize here instead.
        handshake();//from   ww  w.j a  va2s  .c  o m
    } else {
        // channelActive() event has not been fired yet.  this.channelOpen() will be invoked
        // and initialization will occur there.
    }
}

From source file:io.grpc.alts.internal.TsiFrameHandler.java

License:Apache License

@Override
public void handlerAdded(ChannelHandlerContext ctx) throws Exception {
    super.handlerAdded(ctx);
    assert pendingUnprotectedWrites == null;
    pendingUnprotectedWrites = new PendingWriteQueue(checkNotNull(ctx));
}

From source file:me.ferrybig.javacoding.teamspeakconnector.internal.handler.ChannelWriteabilityQueueHandler.java

License:Open Source License

@Override
public void handlerAdded(ChannelHandlerContext ctx) throws Exception {
    super.handlerAdded(ctx);
    queue = new PendingWriteQueue(ctx);
}