Class LocalHostStringLookup

  • All Implemented Interfaces:
    StringLookup

    final class LocalHostStringLookup
    extends AbstractStringLookup
    Looks up keys related to the local host: host name, canonical host name, host address.

    The lookup keys are:

    • name: for the local host name, for example EXAMPLE.
    • canonical-name: for the local canonical host name, for example EXAMPLE.apache.org.
    • address: for the local host address, for example 192.168.56.1.
    Since:
    1.3
    • Constructor Detail

      • LocalHostStringLookup

        private LocalHostStringLookup()
        No need to build instances for now.
    • Method Detail

      • lookup

        public java.lang.String lookup​(java.lang.String key)
        Looks up the value of a local host key.
        Parameters:
        key - the key to be looked up, may be null.
        Returns:
        The value of the environment variable.