Add missing changes from the master branch
This commit is contained in:
parent
16e373cabd
commit
75ce548eda
@ -115,6 +115,15 @@ abstract class AbstractNioChannel<C extends SelectableChannel & WritableByteChan
|
|||||||
this.channel = ch;
|
this.channel = ch;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return the {@link AbstractNioWorker} that handle the IO of the
|
||||||
|
* {@link AbstractNioChannel}
|
||||||
|
*
|
||||||
|
* @return worker
|
||||||
|
*/
|
||||||
|
public AbstractNioWorker getWorker() {
|
||||||
|
return worker;
|
||||||
|
}
|
||||||
public InetSocketAddress getLocalAddress() {
|
public InetSocketAddress getLocalAddress() {
|
||||||
InetSocketAddress localAddress = this.localAddress;
|
InetSocketAddress localAddress = this.localAddress;
|
||||||
if (localAddress == null) {
|
if (localAddress == null) {
|
||||||
|
@ -33,7 +33,7 @@ import java.nio.channels.DatagramChannel;
|
|||||||
/**
|
/**
|
||||||
* Provides an NIO based {@link io.netty.channel.socket.DatagramChannel}.
|
* Provides an NIO based {@link io.netty.channel.socket.DatagramChannel}.
|
||||||
*/
|
*/
|
||||||
final class NioDatagramChannel extends AbstractNioChannel<DatagramChannel>
|
public final class NioDatagramChannel extends AbstractNioChannel<DatagramChannel>
|
||||||
implements org.jboss.netty.channel.socket.DatagramChannel {
|
implements org.jboss.netty.channel.socket.DatagramChannel {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -61,7 +61,11 @@ final class NioDatagramChannel extends AbstractNioChannel<DatagramChannel>
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public NioDatagramWorker getWorker() {
|
||||||
|
return (NioDatagramWorker) super.getWorker();
|
||||||
|
}
|
||||||
|
|
||||||
public boolean isBound() {
|
public boolean isBound() {
|
||||||
return isOpen() && channel.socket().isBound();
|
return isOpen() && channel.socket().isBound();
|
||||||
}
|
}
|
||||||
|
@ -43,6 +43,10 @@ class NioSocketChannel extends AbstractNioChannel<SocketChannel>
|
|||||||
config = new DefaultNioSocketChannelConfig(socket.socket());
|
config = new DefaultNioSocketChannelConfig(socket.socket());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public NioWorker getWorker() {
|
||||||
|
return (NioWorker) super.getWorker();
|
||||||
|
}
|
||||||
|
|
||||||
public NioSocketChannelConfig getConfig() {
|
public NioSocketChannelConfig getConfig() {
|
||||||
return config;
|
return config;
|
||||||
|
Loading…
Reference in New Issue
Block a user