Options
All
  • Public
  • Public/Protected
  • All
Menu

A resource, represented as a JSON object, that is part of the domain data.

Examples:


A subject with one property: "fred's name is Fred"

{
  "@id": "fred",
  "name": "Fred"
}

A subject with a Reference property: "fred's wife is wilma"

{
  "@id": "fred",
  "wife": { "@id": "wilma" }
}

A subject with another nested subject: "fred's wife is wilma, and her name is Wilma"

{
  "@id": "fred",
  "wife": {
    "@id": "wilma",
    "name": "Wilma"
  }
}
see

json-rql subject

Hierarchy

  • Pattern
    • Subject

Indexable

[key: string]: SubjectPropertyObject | Context | undefined

Specifies a graph edge, that is, a mapping from the @id of this subject to a set of one or more values.

Examples:


A subject with one property: "fred's name is Fred"

{
  "@id": "fred",
  "name": "Fred"
}

A subject with a Reference property: "fred's wife is wilma"

{
  "@id": "fred",
  "wife": { "@id": "wilma" }
}

A subject with another nested subject: "fred's wife is wilma, and her name is Wilma"

{
  "@id": "fred",
  "wife": {
    "@id": "wilma",
    "name": "Wilma"
  }
}
see

json-rql subject

Index

Properties

Properties

Optional @context

@context: Context

A JSON-LD Context for the query. In an API, this will frequently be implicit. For example, using json-rql as the body of a POST to http://example.com/my-api/v1/person/query might have the implicit context of a Person (possibly found at http://example.com/my-api/v1/person).

see

examples

Optional @id

@id: Iri | Variable

The unique identity of the subject in the domain.

🚧 Subjects strictly need not be identified with an @id, but the data of such Subjects cannot be retrieved with a simple Describe query.

Optional @type

@type: Iri | Variable | Iri[] | Variable[]

The type of the subject, as an IRI or set of IRIs. (@type is actually shorthand for the RDF property rdf:type.)

Legend

  • Constructor
  • Property
  • Method
  • Property
  • Method
  • Inherited property
  • Inherited method
  • Static property
  • Static method
  • Protected method

Generated using TypeDoc. Delivered by Vercel. @m-ld/m-ld - v0.10.0 Source code licensed MIT. Privacy policy