Interface LinkDescription


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

    Modifier and Type
    Method
    Description
    Get the content type of the content delivered when following the link.
    Get the hrefs defined in the link.
    Get the relation defined in the link.
    Get the scope of the link.
    boolean
    Get whether the link should be considered absolute or not.
  • Method Details

    • getHref

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

      @Nonnull 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 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.