Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 4 of 4 for getUrlHost (0.06 seconds)

  1. src/main/java/org/codelibs/fess/util/IpAddressUtil.java

         * For IPv4 addresses, returns the address as-is.
         *
         * @param address the InetAddress to format
         * @return the URL-safe host string
         */
        public static String getUrlHost(final InetAddress address) {
            if (address == null) {
                return null;
            }
            if (address instanceof Inet6Address) {
                final String hostAddress = address.getHostAddress();
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Thu Nov 06 08:31:03 GMT 2025
    - 9.4K bytes
    - Click Count (0)
  2. src/test/java/org/codelibs/fess/util/IpAddressUtilTest.java

            assertEquals("127.0.0.1", IpAddressUtil.getUrlHost(ipv4Localhost));
    
            // IPv6 localhost
            InetAddress ipv6Localhost = InetAddress.getByName("::1");
            assertEquals("[::1]", IpAddressUtil.getUrlHost(ipv6Localhost));
    
            // Null
            assertNull(IpAddressUtil.getUrlHost(null));
        }
    
        @Test
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Thu Nov 06 08:31:03 GMT 2025
    - 8.9K bytes
    - Click Count (0)
  3. src/main/java/org/codelibs/fess/app/web/admin/maintenance/AdminMaintenanceAction.java

                final String hostname = ia.getHostName();
                if (StringUtil.isNotBlank(hostname)) {
                    buf.append(hostname);
                }
                final String ip = IpAddressUtil.getUrlHost(ia);
                if (StringUtil.isNotBlank(ip)) {
                    if (buf.length() > 0) {
                        buf.append(" : ");
                    }
                    buf.append(ip);
                }
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Sat Mar 28 06:59:19 GMT 2026
    - 23K bytes
    - Click Count (0)
  4. src/main/java/org/codelibs/fess/helper/SystemHelper.java

                return env.get("COMPUTERNAME");
            }
            if (env.containsKey("HOSTNAME")) {
                return env.get("HOSTNAME");
            }
            try {
                return IpAddressUtil.getUrlHost(InetAddress.getLocalHost());
            } catch (final UnknownHostException e) {
                logger.debug("Unknown hostname.", e);
            }
            return "Unknown";
        }
    
        /**
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Sat Mar 28 06:59:19 GMT 2026
    - 43.2K bytes
    - Click Count (0)
Back to Top