Interface LinkDescription


  • @ProviderType
    public interface LinkDescription
    A description of a link defined in the model.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.String getContentType()
      Get the content type of the content delivered when following the link.
      java.lang.Iterable<java.lang.String> getHref()
      Get the hrefs defined in the link.
      java.lang.String getRelation()
      Get the relation defined in the link.
      ApiLink.SCOPE getScope()
      Get the scope of the link.
      boolean isAbsolute()
      Get whether the link should be considered absolute or not.
    • Method Detail

      • getHref

        @Nonnull
        java.lang.Iterable<java.lang.String> getHref()
        Get the hrefs defined in the link.
        Returns:
        The hrefs.
      • getRelation

        @Nonnull
        java.lang.String getRelation()
        Get the relation defined in the link.
        Returns:
        The link's relation
      • getScope

        @Nonnull
        ApiLink.SCOPE getScope()
        Get the scope of the link. The scope can be used to decide when to serialize the link. Whether it is serialized for a main entity, a child entity or both.
        Returns:
        The links scope.
      • getContentType

        @CheckForNull
        java.lang.String getContentType()
        Get the content type of the content delivered when following the link.
        Returns:
        The content type.
      • isAbsolute

        boolean isAbsolute()
        Get whether the link should be considered absolute or not.
        Returns:
        Whether the link is absolute or not.