Here you can find the source of isStart0(String host, int port)
public static boolean isStart0(String host, int port)
//package com.java2s; //License from project: Open Source License import java.net.Socket; public class Main { public static boolean isStart0(String host, int port) { boolean status = false; Socket socket = null;//from w w w.j a v a 2 s .c o m try { socket = new Socket(host, port); status = true; socket.close(); } catch (Exception e) { } finally { } return status; } }