Class Alias

class for aliases

Constructors

Properties

Accessors

Methods

Constructors

  • Parameters

    • alias: LabelAndDescription

      the alias in json format

    Returns Alias

    Example

    const Alias = new Alias({ language: 'en', value: 'Douglas Adams' });
    

Properties

language: LabelLanguages

the language of the alias

value: string

the value of the alias

Accessors

  • get internalID(): string
  • create a unique id for the Alias

    Returns string

    the id

Methods

  • this function checks if two Aliases are equal

    Parameters

    • other: LabelAndDescription

      the other Label

    Returns boolean

    true if the Aliases are equal

    Example

    const alias1 = new Alias({ language: 'en', value: 'foo' });
    const alias2 = new Alias({ language: 'en', value: 'bar' });

    alias1.equals(alias2); // false
  • Returns LabelAndDescription

    the alias in a json format

    Example

    const json = alias.toJson();
    
  • create a Alias from a language and a value

    Parameters

    • language: LabelLanguages

      the language of the Alias

    • value: string

      the value of the Alias

    Returns Alias

    the Alias object

    Example

    const Alias = Alias.fromString('en', 'Douglas Adams')
    

Generated using TypeDoc