Class LinkType

    • Constructor Detail

      • LinkType

        public LinkType()
    • Method Detail

      • getId

        @NotNull
        public abstract @NotNull String getId()
        Returns:
        Link type ID (is stored as identifier in repository)
      • getLabel

        @NotNull
        public @NotNull String getLabel()
        Returns:
        Link type label (displayed in link dialogs)
      • getPrimaryLinkRefProperty

        @Nullable
        public abstract @Nullable String getPrimaryLinkRefProperty()
        Returns:
        Name of the property in which the primary link reference is stored
      • accepts

        public boolean accepts​(@NotNull
                               @NotNull LinkRequest linkRequest)
        Checks whether a link reference can be handled by this link type
        Parameters:
        linkRequest - Link reference
        Returns:
        true if this link type can handle the given link reference
      • accepts

        public abstract boolean accepts​(@NotNull
                                        @NotNull String linkRef)
        Checks whether a link reference string can be handled by this link type
        Parameters:
        linkRef - Link reference string
        Returns:
        true if this link type can handle the given link reference
      • resolveLink

        @NotNull
        public abstract @NotNull Link resolveLink​(@NotNull
                                                  @NotNull Link link)
        Resolves a link
        Parameters:
        link - Link metadata
        Returns:
        Resolved link metadata. Never null.