Java Local Host Get getLocalHost()

Here you can find the source of getLocalHost()

Description

get Local Host

License

Apache License

Declaration

public static InetAddress getLocalHost() 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import java.net.InetAddress;
import java.net.UnknownHostException;

public class Main {
    public static InetAddress getLocalHost() {
        try {//  w  w w . jav a 2s.  com
            return InetAddress.getLocalHost();
        } catch (UnknownHostException e) {
            throw new AssertionError(e);
        }
    }
}

Related

  1. getLocalhost()
  2. getLocalHost()
  3. getLocalHost()
  4. getLocalHost()
  5. getLocalHost()
  6. getLocalHost()
  7. getLocalHost()
  8. getLocalHost()
  9. getLocalHost()