Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Variable

Variables are placeholders used in patterns to be matched. In cwm they are symbols which are the formula's list of quantified variables. In sparql they are not visibly URIs. Here we compromise, by having a common special base URI for variables. Their names are uris, but the ? notation has an implicit base uri of 'varid:'

Hierarchy

Implements

  • TFVariable

Index

Constructors

constructor

Properties

base

base: string = 'varid:'

The base string for a variable's name

classOrder

classOrder: number = ClassOrder.Variable

The class order for this node

isVar

isVar: number = 1

termType

termType: "Variable" = VariableTermType

The type of node

uri

uri: string

The unique identifier of this variable

value

value: string

The node's value

Static fromValue

fromValue: <T>(value: ValueType) => T

Type declaration

    • <T>(value: ValueType): T
    • Type parameters

      • T: FromValueReturns<any>

      Parameters

      • value: ValueType

      Returns T

Static toJS

toJS: (term: any) => string | boolean | object | Number | Date | (string | boolean | object | Number | Date)[]

Type declaration

    • (term: any): string | boolean | object | Number | Date | (string | boolean | object | Number | Date)[]
    • Parameters

      • term: any

      Returns string | boolean | object | Number | Date | (string | boolean | object | Number | Date)[]

Methods

compareTerm

  • compareTerm(other: Node): number

equals

  • equals(other: any): boolean
  • Compares whether the two nodes are equal

    Parameters

    • other: any

    Returns boolean

hashString

  • hashString(): string

sameTerm

  • sameTerm(other: Node): boolean

substitute

  • substitute(bindings: any): any
  • Creates the substituted node for this one, according to the specified bindings

    Parameters

    • bindings: any

    Returns any

toCanonical

  • toCanonical(): string

toNQ

  • toNQ(): string

toNT

  • toNT(): string

toString

  • toString(): string

Static toString

  • toString(variable: any): string

Generated using TypeDoc