File

src/lib/src/hal-link.ts

Description

Hyperlink according to [JSON HAL specification draft]{@link https://tools.ietf.org/html/draft-kelly-json-hal-08}.

Index

Properties

Properties

deprecation
deprecation: string
Type : string

Its presence indicates that the link is to be deprecated (i.e. removed) at a future date. Its value is a URL that SHOULD provide further information about the deprecation.

href
href: string
Type : string

URI according to RFC3986.

hreflang
hreflang: string
Type : string

Its value is a string and is intended for indicating the language of the target resource (as defined by RFC5988).

name
name: string
Type : string

Its value MAY be used as a secondary key for selecting Link Objects, which share the same relation type.

profile
profile: string
Type : string

Its value is a string which is a URI that hints about the profile of the target resource.

templated
templated: boolean
Type : boolean

Its value is boolean and SHOULD be true when the Link Object's "href" property is a URI Template.

Its value SHOULD be considered false if it is undefined or any other value than true.

title
title: string
Type : string

Its value is a string and is intended for labelling the link with a human-readable identifier (as defined by RFC5988).

type
type: string
Type : string

Its value is a string used as a hint to indicate the media type expected when dereferencing the target resource.

export interface Link {
  /**
   * URI according to RFC3986.
   */
  readonly href: string;
  /**
   * Its value is a string used as a hint to indicate the media type expected when dereferencing the target resource.
   */
  readonly type?: string;
  /**
   * Its presence indicates that the link is to be deprecated (i.e. removed) at a future date.
   * Its value is a URL that SHOULD provide further information about the deprecation.
   */
  readonly deprecation?: string;
  /**
   * Its value MAY be used as a secondary key for selecting Link Objects, which share the same relation type.
   */
  readonly name?: string;
  /**
   * Its value is a string and is intended for labelling the link with a human-readable identifier (as defined by RFC5988).
   */
  readonly title?: string;
  /**
   * Its value is a string and is intended for indicating the language of the target resource (as defined by RFC5988).
   */
  readonly hreflang?: string;
  /**
   * Its value is boolean and SHOULD be true when the Link Object's "href"
   * property is a URI Template.
   *
   * Its value SHOULD be considered false if it is undefined or any other
   * value than true.
   */
  readonly templated?: boolean;
  /**
   * Its value is a string which is a URI that hints about the profile of the target resource.
   */
  readonly profile?: string;
}

results matching ""

    No results matching ""