Class NetUtil


  • public class NetUtil
    extends Object
    A static class which contains information methods. In a future version it may contain more useful utility methods.
    Author:
    Hanns Holger Rutz
    • Method Detail

      • main

        public static void main​(String[] args)
        This method gets called when one tries to start the .jar file directly. It prints copyright information and quits. It also offers to run some built-in tests.
      • getVersion

        public static final double getVersion()
        Returns the library's version.
        Returns:
        the current version of NetUtil
      • getCopyrightString

        public static final String getCopyrightString()
        Returns a copyright information string about the library
        Returns:
        text string which can be displayed in an about box
      • getCreditsString

        public static final String getCreditsString()
        Returns a license and website information string about the library
        Returns:
        text string which can be displayed in an about box
      • getResourceString

        public static final String getResourceString​(String key)
        Returns a string from the library's string resource bundle (currently localized english and german). This is used by the classes of the library, you shouldn't use it yourself.
        Parameters:
        key - lookup dictionary key
        Returns:
        (localized) human readable string for the given key or placeholder string if the resource wasn't found