package com.tagmae.tsgame_erwang;

/**
 * 作者：YMI on 2017/12/7 16:53
 * 邮箱：18702631465@163.com
 * QQ:1078561230
 * 
 * 已更新为使用新的HTTP服务器
 */

public class webserverInstance {
    private static webserverInstance Instance;
    
    public static webserverInstance getInstance() {
        if (null == Instance) {
            // http://localhost:4477/testurl
            Instance = new webserverInstance();
        }
        return Instance;
    }

    public void creat() {
        // 使用新的HTTP服务器
        NewWebServerInstance.getInstance().create(4477);
    }

    public boolean iscreatandrun() {
        return NewWebServerInstance.getInstance().isRunning();
    }

    public void webclose() {
        NewWebServerInstance.getInstance().stop();
    }
}
