package net.glowstone.net;

import io.netty.channel.ChannelFuture;
import java.net.InetSocketAddress;
import java.util.concurrent.CountDownLatch;
import net.glowstone.GlowServer;

/**
 * Represents a network server.
 *
 * Modified implementation of {@link com.flowpowered.network.NetworkServer}.
 */
public abstract class GlowNetworkServer {

    private final GlowServer server;
    protected CountDownLatch latch;

    public GlowNetworkServer(GlowServer server, CountDownLatch latch) {
        this.server = server;
        this.latch = latch;
    }

    public abstract ChannelFuture bind(InetSocketAddress address);

    public GlowServer getServer() {
        return server;
    }

    public void onBindSuccess(InetSocketAddress address) {
        latch.countDown();
    }

    public abstract void onBindFailure(InetSocketAddress address, Throwable t);

    public abstract void shutdown();
}

@@ -215,16 +215,19 @@
 .%0A *%0A * 
+%3Cp%3E
 Modified
@@ -413,16 +413,257 @@
 latch;%0A%0A
+    /**%0A     * Creates an instance for the specified server.%0A     *%0A     * @param server the associated GlowServer%0A     * @param latch The countdown latch used during server startup to wait for network server%0A     *         binding.%0A     */%0A
     publ

Fix CheckStyle issues in net/GlowNetworkServer.java (#662)