iwf
    Preparing search index...

    Class StringSnak

    Class for the StringSnak.

    Most used property of this type P1545 (series ordinal).

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    datatype: string = 'string'
    hash: undefined | string
    property: `P${number}`
    snaktype: SnakType
    value: undefined | string

    Accessors

    • get hasValue(): boolean

      Checks if the snak has a value.

      Returns boolean

      True if the snak has a value.

    • get internalID(): string

      Creates a unique ID for the Snak.

      Returns string

      The ID.

    Methods

    • This function checks if two snaks are equal.

      Parameters

      Returns boolean

      True if the snaks are equal.

      if (stringSnak.equals(other)) {
      // do something
      }
    • Parameters

      • property: `P${number}`

        The property of the snak in 'P-form'.

      • string: string

        The string.

      Returns StringSnak

      A snak with the given properties.

      if (snak.equals(other)) {
      // do something
      }