tmql

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 18, 2022 License: Apache-2.0 Imports: 4 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package tmql implements decoding TMQL queries.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Parse

func Parse(r io.Reader, v interface{}) error

func ParseBytes

func ParseBytes(b []byte, v interface{}) error

func ParseString

func ParseString(s string, v interface{}) error

Types

type Anchor

type Anchor struct {
	Constant *Constant `  @@`
	Variable string    `| @Variable | @"."`
}

TMQL [20] anchor

http://www.isotopicmaps.org/tmql/tmql.html#anchor

type Atom

type Atom struct {
	Keyword Keyword `( @"undef" | @"true" | @"false" )`
	Number  *int    `| @Int`
	String  *string `| @String`
}

TMQL [2] atom

http://www.isotopicmaps.org/tmql/tmql.html#atom

type Axis

type Axis int

TMQL [18] axis

http://www.isotopicmaps.org/tmql/tmql.html#axis

const (
	UnspecifiedAxis Axis = iota
	TypesAxis
	SupertypesAxis
	PlayersAxis
	RolesAxis
	TraverseAxis
	CharacteristicsAxis
	ScopeAxis
	LocatorsAxis
	IndicatorsAxis
	ItemAxis
	ReifierAxis
	AtomifyAxis
)

func (*Axis) Capture

func (a *Axis) Capture(s []string) error

func (Axis) String

func (a Axis) String() string

type BindingSet

type BindingSet struct {
	VariableAssignments []*VariableAssignment `@@ ( "," @@ )*`
}

TMQL [45] binding-set

http://www.isotopicmaps.org/tmql/tmql.html#binding-set

type BooleanExpression

type BooleanExpression struct {
	BooleanPrimitive *BooleanPrimitive `@@`
}

TMQL [38] boolean-expression

http://www.isotopicmaps.org/tmql/tmql.html#boolean-expression

type BooleanPrimitive

type BooleanPrimitive struct {
	Negated      *BooleanPrimitive `  "not" @@`
	ForallClause *ForallClause     `| @@`
	ExistsClause *ExistsClause     `| @@`
}

TMQL [39] boolean-primitive

http://www.isotopicmaps.org/tmql/tmql.html#boolean-primitive

type CompositeContent

type CompositeContent struct {
	Content   *Content   `@@`
	OpContent *OpContent `@@*`
}

type Constant

type Constant struct {
	Atom          *Atom          `  @@`
	ItemReference *ItemReference `| @@`
}

TMQL [1] constant

http://www.isotopicmaps.org/tmql/tmql.html#constant

type Content

type Content struct {
	QueryExpression *QueryExpression `  "{" @@ "}"`
	PathExpression  *PathExpression  `| @@`
}

TMQL [23] content

http://www.isotopicmaps.org/tmql/tmql.html#content

type ExistsClause

type ExistsClause struct {
	ExistsQuantifier  *ExistsQuantifier  `( @@`
	BindingSet        *BindingSet        `  @@`
	BooleanExpression *BooleanExpression `  "satisfies" @@ )`
	ExistsContent     *CompositeContent  `| "exists"? @@`
}

TMQL [40] exists-clause

http://www.isotopicmaps.org/tmql/tmql.html#exists-clause

type ExistsQuantifier

type ExistsQuantifier struct {
	Some  bool `  @"some"`
	Least int  `| "at" ( "least" @Int`
	Most  int  `       | "most" @Int )`
}

TMQL [41] exists-quantifier

http://www.isotopicmaps.org/tmql/tmql.html#exists-quantifier

type ForallClause

type ForallClause struct {
	BindingSet        *BindingSet        `"every" @@`
	BooleanExpression *BooleanExpression `"satisfies" @@`
}

TMQL [42] forall-clause

http://www.isotopicmaps.org/tmql/tmql.html#forall-clause

type ItemReference

type ItemReference struct {
	Identifier string `  @Identifier`
	QIRI       string `| @QIRI`
}

TMQL [17] item-reference

http://www.isotopicmaps.org/tmql/tmql.html#item-reference

type Keyword

type Keyword string
const (
	UndefKeyword Keyword = "undef"
	TrueKeyword  Keyword = "true"
	FalseKeyword Keyword = "false"
)

func (*Keyword) Capture

func (k *Keyword) Capture(s []string) error

type OpContent

type OpContent struct {
	ContentInfixOperator string   `( @"++" | @"--" | @"==" )`
	Content              *Content `@@`
}

type PathExpression

type PathExpression struct {
	PostfixedExpression *PostfixedExpression `@@`
}

TMQL [53] path-expression

http://www.isotopicmaps.org/tmql/tmql.html#path-expression

type Postfix

type Postfix struct {
	// TMQL [56] filter-postfix
	//
	// http://www.isotopicmaps.org/tmql/tmql.html#filter-postfix
	FilterPostfix *BooleanPrimitive `"[" @@ "]"`
}

TMQL [55] postfix

http://www.isotopicmaps.org/tmql/tmql.html#postfix

type PostfixedExpression

type PostfixedExpression struct {
	TupleExpression *TupleExpression `( @@`
	SimpleContent   *SimpleContent   `| @@ )`
	Postfix         []*Postfix       `@@*`
}

TMQL [54] postfixed-expression

http://www.isotopicmaps.org/tmql/tmql.html#postfixed-expression

type QName

type QName struct {
	Prefix     string `@Prefix`
	Identifier string `@Identifier`
}

TMQL [14] QName

http://www.isotopicmaps.org/tmql/tmql.html#QName

type QueryExpression

type QueryExpression struct {
	PathExpression *PathExpression `@@`
}

TMQL [46] query-expression

http://www.isotopicmaps.org/tmql/tmql.html#query-expression

type SimpleContent

type SimpleContent struct {
	Anchor     *Anchor `@@`
	Navigation []*Step `@@*`
}

TMQL [21] simple-content

http://www.isotopicmaps.org/tmql/tmql.html#simple-content

type Step

type Step struct {
	Direction StepDirection `( @">>" | @"<<" )`
	Axis      Axis          `` /* 248-byte string literal not displayed */

	Anchor *Anchor `@@?`
}

TMQL [18] step

http://www.isotopicmaps.org/tmql/tmql.html#step

type StepDirection

type StepDirection int
const (
	StepForward StepDirection = iota
	StepBackward
)

func (*StepDirection) Capture

func (sd *StepDirection) Capture(s []string) error

type TupleExpression

type TupleExpression struct {
	Null bool `@Null`
}

TMQL [24] tuple-expression

http://www.isotopicmaps.org/tmql/tmql.html#tuple-expression

type VariableAssignment

type VariableAssignment struct {
	Variable         string            `@Variable`
	CompositeContent *CompositeContent `"in" @@`
}

TMQL [44] variable-assignment

http://www.isotopicmaps.org/tmql/tmql.html#variable-assignment

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL