Example usage for java.util.logging SocketHandler SocketHandler

List of usage examples for java.util.logging SocketHandler SocketHandler

Introduction

In this page you can find the example usage for java.util.logging SocketHandler SocketHandler.

Prototype

public SocketHandler(String host, int port) throws IOException 

Source Link

Document

Construct a SocketHandler using a specified host and port.

Usage

From source file:Main.java

public Main(String host, int port) {
    try {// w  w  w.  j av a 2  s.com
        handler = new SocketHandler(host, port);
        logger.addHandler(handler);
    } catch (IOException ioe) {
        ioe.printStackTrace();
    }
}