Interface DiscoveryResult

  • @NonNullByDefault
    public interface DiscoveryResult
    The DiscoveryResult is a container for one result of a discovery process. The discovery process can lead to 0..N DiscoveryResult objects which are fired as an event to registered DiscoveryListeners.
    Kai Kreuzer - Initial contribution, Andre Fuechsel - added support for time to live, Thomas Höfer - Added representation
    See Also:
    DiscoveryService, DiscoveryListener
    • Method Detail

      • getThingUID

        ThingUID getThingUID()
        Returns the unique Thing ID of this result object.

        A ThingUID must be a unique identifier of a concrete Thing which must not consist of data which could change (e.g. configuration data such as an IP address). If a Thing disappears and is discovered again, the same Thing ID must be created. A typical Thing ID could be the serial number. It's usually not a product number.

        the Thing ID
      • getThingTypeUID

        ThingTypeUID getThingTypeUID()
        Returns the unique Thing type ID of this result object.

        A Thing type ID could be a product number which identifies the same type of Things. It's usually not a serial number.

        the unique Thing type
      • getBindingId

        String getBindingId()
        Returns the binding ID of this result object.

        The binding ID is extracted from the unique Thing ID.

        the binding ID
      • getProperties

        Map<String,​Object> getProperties()
        Returns the properties of this result object.
        The properties contain information which become part of a Thing.

        Hint: The returned properties are immutable.

        the properties (could be empty)
      • getRepresentationProperty

        @Nullable String getRepresentationProperty()
        Returns the representation property of this result object.

        The representation property represents an unique human and/or machine readable identifier of the thing that was discovered. Its actual value can be retrieved from the getProperties() map. Such unique identifiers are typically the ipAddress, the macAddress or the serialNumber of the discovered thing.

        the representation property
      • getLabel

        String getLabel()
        Returns the human readable label for this result object.
        the human readable label (could be empty)
      • getBridgeUID

        @Nullable ThingUID getBridgeUID()
        Returns the unique Bridge ID of this result object.
        the unique Bridge ID
      • getTimestamp

        long getTimestamp()
        Returns the timestamp of this result object.
        timestamp as long
      • getTimeToLive

        long getTimeToLive()
        Returns the time to live in seconds for this entry.
        time to live in seconds