Class UID

Direct Known Subclasses:
ChannelGroupTypeUID, ChannelGroupUID, ChannelTypeUID, ChannelUID, ProfileTypeUID, ThingTypeUID, ThingUID

@NonNullByDefault public abstract class UID extends AbstractUID
Base class for binding related unique identifiers.

A UID must always start with a binding ID.

Author:
Dennis Nobel - Initial contribution, Oliver Libutzki - Added possibility to define UIDs with variable amount of segments, Jochen Hiller - Bugfix 455434: added default constructor, object is now mutable
  • Constructor Details

    • UID

      public UID()
      For reflection only. Constructor must be public, otherwise it cannot be called by subclasses from another package.
    • UID

      public UID(String uid)
      Parses a UID for a given string. The UID must be in the format 'bindingId:segment:segment:...'.
      Parameters:
      uid - uid in form a string
    • UID

      public UID(String... segments)
      Creates a UID for list of segments.
      Parameters:
      segments - segments
    • UID

      protected UID(List<String> segments)
      Creates a UID for list of segments.
      Parameters:
      segments - segments
  • Method Details