Class NameRegister.UniqueNamePerInterface

    • Field Detail

      • _hostNames

        private final java.util.concurrent.ConcurrentMap<java.net.InetAddress,​java.lang.String> _hostNames
      • _serviceNames

        private final java.util.concurrent.ConcurrentMap<java.net.InetAddress,​java.util.Set<java.lang.String>> _serviceNames
    • Constructor Detail

      • UniqueNamePerInterface

        public UniqueNamePerInterface()
    • Method Detail

      • register

        public void register​(java.net.InetAddress networkInterface,
                             java.lang.String name,
                             NameRegister.NameType type)
        Description copied from interface: NameRegister
        Registers a name that is defended by this group of mDNS.
        Parameters:
        networkInterface - IP address to handle
        name - name to register
        type - name type to register
      • checkName

        public boolean checkName​(java.net.InetAddress networkInterface,
                                 java.lang.String name,
                                 NameRegister.NameType type)
        Description copied from interface: NameRegister
        Checks a name that is defended by this group of mDNS.
        Parameters:
        networkInterface - IP address to handle
        name - name to check
        type - name type to check
        Returns:
        true if the name is not in conflict, flase otherwise.
      • incrementName

        public java.lang.String incrementName​(java.net.InetAddress networkInterface,
                                              java.lang.String name,
                                              NameRegister.NameType type)
        Description copied from interface: NameRegister
        Increments a name that is defended by this group of mDNS after it has been found in conflict.
        Parameters:
        networkInterface - IP address to handle
        name - name to increment
        type - name type to increments
        Returns:
        new name