diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/ServerConnector.java b/jetty-server/src/main/java/org/eclipse/jetty/server/ServerConnector.java index 70dab444d05..399bff510fe 100644 --- a/jetty-server/src/main/java/org/eclipse/jetty/server/ServerConnector.java +++ b/jetty-server/src/main/java/org/eclipse/jetty/server/ServerConnector.java @@ -274,6 +274,20 @@ public class ServerConnector extends AbstractNetworkConnector _inheritChannel = inheritChannel; } + + public ServerSocketChannel getAcceptChannel() + { + return _acceptChannel; + } + + public void setAcceptChannel(ServerSocketChannel acceptChannel) + { + if (isStarted()) + throw new IllegalStateException(getState()); + updateBean(_acceptChannel,acceptChannel); + _acceptChannel = acceptChannel; + } + @Override public void open() throws IOException { @@ -288,6 +302,7 @@ public class ServerConnector extends AbstractNetworkConnector } } + /** * Called by {@link #open()} to obtain the accepting channel. * @return ServerSocketChannel used to accept connections.