Rename future to promise in the ChannelDuplexHandler method arguments.
Motivation: We used future in many method of ChannelDuplexHandler as argument name of ChannelPromise. We should make it more consistent and correct. Modifications: Replace future with promise. Result: More correct and consistent naming.
This commit is contained in:
parent
d97129b4c0
commit
44b942e507
@ -34,8 +34,8 @@ public class ChannelDuplexHandler extends ChannelInboundHandlerAdapter implement
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public void bind(ChannelHandlerContext ctx, SocketAddress localAddress,
|
public void bind(ChannelHandlerContext ctx, SocketAddress localAddress,
|
||||||
ChannelPromise future) throws Exception {
|
ChannelPromise promise) throws Exception {
|
||||||
ctx.bind(localAddress, future);
|
ctx.bind(localAddress, promise);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -46,8 +46,8 @@ public class ChannelDuplexHandler extends ChannelInboundHandlerAdapter implement
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public void connect(ChannelHandlerContext ctx, SocketAddress remoteAddress,
|
public void connect(ChannelHandlerContext ctx, SocketAddress remoteAddress,
|
||||||
SocketAddress localAddress, ChannelPromise future) throws Exception {
|
SocketAddress localAddress, ChannelPromise promise) throws Exception {
|
||||||
ctx.connect(remoteAddress, localAddress, future);
|
ctx.connect(remoteAddress, localAddress, promise);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -57,9 +57,9 @@ public class ChannelDuplexHandler extends ChannelInboundHandlerAdapter implement
|
|||||||
* Sub-classes may override this method to change behavior.
|
* Sub-classes may override this method to change behavior.
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public void disconnect(ChannelHandlerContext ctx, ChannelPromise future)
|
public void disconnect(ChannelHandlerContext ctx, ChannelPromise promise)
|
||||||
throws Exception {
|
throws Exception {
|
||||||
ctx.disconnect(future);
|
ctx.disconnect(promise);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -69,8 +69,8 @@ public class ChannelDuplexHandler extends ChannelInboundHandlerAdapter implement
|
|||||||
* Sub-classes may override this method to change behavior.
|
* Sub-classes may override this method to change behavior.
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public void close(ChannelHandlerContext ctx, ChannelPromise future) throws Exception {
|
public void close(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception {
|
||||||
ctx.close(future);
|
ctx.close(promise);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -80,8 +80,8 @@ public class ChannelDuplexHandler extends ChannelInboundHandlerAdapter implement
|
|||||||
* Sub-classes may override this method to change behavior.
|
* Sub-classes may override this method to change behavior.
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public void deregister(ChannelHandlerContext ctx, ChannelPromise future) throws Exception {
|
public void deregister(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception {
|
||||||
ctx.deregister(future);
|
ctx.deregister(promise);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
x
Reference in New Issue
Block a user