public void run() {
        
        String msg = this.read();

        if(msg.matches("^NEW\\s([a-zA-Z0-9]+)$")){
            /* Create User */
            String name = msg.substring(4);
            String host = socket.getInetAddress().toString().substring(1);
            this.user = new User(name, host);
            ChatServer.addUser(this.user);
            this.write("OK");
        }

        while((msg = this.read()) != null){

            if(msg.equals("INFO")){
                this.write("LIST " + ChatServer.getSize() + " " + ChatServer.getUser());
            }else if(msg.equals("BYE")){
                this.write("BYE");
                ChatServer.delUser(this.user);
                break;
            }else{
                this.write("ERROR Unknowen command '" + msg + "'");
                ChatServer.delUser(this.user);
                break;
            }
        }

        /* Close connection */
        this.close();

    }