Package com.slytechs.utils.net

Examples of com.slytechs.utils.net.IpAddress


    displayName = netint.getDisplayName();
    timezome = TimeZone.getDefault().getRawOffset();

    Enumeration<InetAddress> e = netint.getInetAddresses();
    while (e.hasMoreElements()) {
      addresses.add(new IpAddress(e.nextElement().getAddress()));
    }

  }
View Full Code Here


    /**
     * Try parsing Ipv4 address.
     */
    String[] c;
    if ( (c = word.split("\\.")).length == 4) {
      r = new IpAddress(parseIntoArray(new byte[4], c, 10));

    } else if ( (c = word.split(":")).length == 16) {
      r = new IpAddress(parseIntoArray(new byte[16], c, 16));

    } else if ( (c = word.split("-")).length == 6 || (c = word.split(":")).length == 6) {
      r = new MacAddress(parseIntoArray(new byte[6], c, 16));

    } else if (c.length > 1) { // Catch all. Allow any type of address separated :
View Full Code Here

TOP

Related Classes of com.slytechs.utils.net.IpAddress

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.