@traqula/rules-sparql-1-2 0.0.1-alpha.137
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.txt +22 -0
- package/README.md +15 -0
- package/lib/grammar.d.ts +157 -0
- package/lib/grammar.js +485 -0
- package/lib/grammar.js.map +1 -0
- package/lib/index.cjs +13572 -0
- package/lib/index.d.ts +3 -0
- package/lib/index.js +4 -0
- package/lib/index.js.map +1 -0
- package/lib/lexer.d.ts +53 -0
- package/lib/lexer.js +40 -0
- package/lib/lexer.js.map +1 -0
- package/lib/sparql12Types.d.ts +33 -0
- package/lib/sparql12Types.js +2 -0
- package/lib/sparql12Types.js.map +1 -0
- package/package.json +46 -0
package/lib/index.d.ts
ADDED
package/lib/index.js
ADDED
package/lib/index.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAClC,OAAO,KAAK,GAAG,MAAM,SAAS,CAAC;AAC/B,cAAc,iBAAiB,CAAC","sourcesContent":["export * as gram from './grammar';\nexport * as lex from './lexer';\nexport * from './sparql12Types';"]}
|
package/lib/lexer.d.ts
ADDED
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { LexerBuilder } from '@traqula/core';
|
|
2
|
+
export declare const tilde: import("chevrotain").TokenType & {
|
|
3
|
+
name: "Tilde";
|
|
4
|
+
};
|
|
5
|
+
export declare const annotationOpen: import("chevrotain").TokenType & {
|
|
6
|
+
name: "AnnotationOpen";
|
|
7
|
+
};
|
|
8
|
+
export declare const annotationClose: import("chevrotain").TokenType & {
|
|
9
|
+
name: "AnnotationClose";
|
|
10
|
+
};
|
|
11
|
+
export declare const reificationOpen: import("chevrotain").TokenType & {
|
|
12
|
+
name: "ReificationOpen";
|
|
13
|
+
};
|
|
14
|
+
export declare const reificationClose: import("chevrotain").TokenType & {
|
|
15
|
+
name: "ReificationClose";
|
|
16
|
+
};
|
|
17
|
+
export declare const tripleTermOpen: import("chevrotain").TokenType & {
|
|
18
|
+
name: "TripleTermOpen";
|
|
19
|
+
};
|
|
20
|
+
export declare const tripleTermClose: import("chevrotain").TokenType & {
|
|
21
|
+
name: "TripleTermClose";
|
|
22
|
+
};
|
|
23
|
+
export declare const builtinLangDir: import("chevrotain").TokenType & {
|
|
24
|
+
name: "BuiltInLangdir";
|
|
25
|
+
};
|
|
26
|
+
export declare const builtinStrLangDir: import("chevrotain").TokenType & {
|
|
27
|
+
name: "BuiltInStrLangdir";
|
|
28
|
+
};
|
|
29
|
+
export declare const builtinHasLang: import("chevrotain").TokenType & {
|
|
30
|
+
name: "BuiltInHasLang";
|
|
31
|
+
};
|
|
32
|
+
export declare const builtinHasLangDir: import("chevrotain").TokenType & {
|
|
33
|
+
name: "BuiltInHasLangdir";
|
|
34
|
+
};
|
|
35
|
+
export declare const builtinIsTRIPLE: import("chevrotain").TokenType & {
|
|
36
|
+
name: "BuiltInIsTriple";
|
|
37
|
+
};
|
|
38
|
+
export declare const builtinTRIPLE: import("chevrotain").TokenType & {
|
|
39
|
+
name: "BuiltInTriple";
|
|
40
|
+
};
|
|
41
|
+
export declare const builtinSUBJECT: import("chevrotain").TokenType & {
|
|
42
|
+
name: "BuiltInSubject";
|
|
43
|
+
};
|
|
44
|
+
export declare const builtinPREDICATE: import("chevrotain").TokenType & {
|
|
45
|
+
name: "BuiltInPredicate";
|
|
46
|
+
};
|
|
47
|
+
export declare const builtinOBJECT: import("chevrotain").TokenType & {
|
|
48
|
+
name: "BuiltInObject";
|
|
49
|
+
};
|
|
50
|
+
export declare const LANG_DIR: import("chevrotain").TokenType & {
|
|
51
|
+
name: "LANG_DIR";
|
|
52
|
+
};
|
|
53
|
+
export declare const sparql12Tokens: LexerBuilder<"" | "a" | "DefaultGraph" | "BuiltInStr" | "BuiltInLang" | "BuiltInLangmatches" | "BuiltInDatatype" | "BuiltInBound" | "BuiltInIri" | "BuiltInUri" | "BuiltInBnode" | "BuiltInRand" | "BuiltInAbs" | "BuiltInCeil" | "BuiltInFloor" | "BuiltInRound" | "BuiltInConcat" | "BuiltInStrlen" | "BuiltInUcase" | "BuiltInLcase" | "BuiltInEncode_for_uri" | "BuiltInContains" | "BuiltInStrstarts" | "BuiltInStrends" | "BuiltInStrbefore" | "BuiltInStrafter" | "BuiltInYear" | "BuiltInMonth" | "BuiltInDay" | "BuiltInHours" | "BuiltInMinutes" | "BuiltInSeconds" | "BuiltInTimezone" | "BuiltInTz" | "BuiltInNow" | "BuiltInUuid" | "BuiltInStruuid" | "BuiltInMd5" | "BuiltInSha1" | "BuiltInSha256" | "BuiltInSha384" | "BuiltInSha512" | "BuiltInCoalesce" | "BuiltInIf" | "BuiltInStrlang" | "BuiltInStrdt" | "BuiltInSameterm" | "BuiltInIsiri" | "BuiltInIsuri" | "BuiltInIsblank" | "BuiltInIsliteral" | "BuiltInIsnumeric" | "BuiltInRegex" | "BuiltInSubstr" | "BuiltInReplace" | "BuiltInExists" | "BuiltInNotexists" | "BuiltInCount" | "BuiltInSum" | "BuiltInMin" | "BuiltInMax" | "BuiltInAvg" | "BuiltInSample" | "BuiltInGroup_concat" | "NamedGraph" | "Graph" | "GraphAll" | "LCurly" | "RCurly" | "Dot" | "Comma" | "Semi" | "LParen" | "RParen" | "LSquare" | "RSquare" | "Pipe" | "Slash" | "Hat" | "Question" | "Star" | "OpPlus" | "OpMinus" | "Exclamation" | "LogicAnd" | "LogicOr" | "Equal" | "NotEqual" | "LessThan" | "GreaterThan" | "LessThanEqual" | "GreaterThanEqual" | "Hathat" | "IriRef" | "PNameLn" | "PNameNs" | "BlankNodeLabel" | "Var1" | "Var2" | "Integer" | "Decimal" | "Double" | "InterferePositive" | "DecimalPositive" | "DoublePositive" | "IntegerNegative" | "DecimalNegative" | "DoubleNegative" | "StringLiteral1" | "StringLiteral2" | "StringLiteralLong1" | "StringLiteralLong2" | "Ws" | "Comment" | "Nil" | "Anon" | "BaseDecl" | "PrefixDecl" | "Select" | "Distinct" | "Reduced" | "As" | "Construct" | "Describe" | "Ask" | "From" | "Where" | "GroupBy" | "Having" | "Order" | "OrderAsc" | "OrderDesc" | "Limit" | "Offset" | "Values" | "Load" | "Silent" | "LoadInto" | "Clear" | "Drop" | "Create" | "Add" | "To" | "Move" | "Copy" | "ModifyWith" | "DeleteClause" | "InsertClause" | "DataClause" | "UsingClause" | "Optional" | "Service" | "Bind" | "Undef" | "Minus" | "Union" | "Filter" | "True" | "False" | "In" | "NotIn" | "Separator" | "Tilde" | "AnnotationOpen" | "AnnotationClose" | "ReificationOpen" | "ReificationClose" | "TripleTermOpen" | "TripleTermClose" | "BuiltInLangdir" | "BuiltInStrLangdir" | "BuiltInHasLang" | "BuiltInHasLangdir" | "BuiltInIsTriple" | "BuiltInTriple" | "BuiltInSubject" | "BuiltInPredicate" | "BuiltInObject" | "LANG_DIR">;
|
package/lib/lexer.js
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/* eslint-disable require-unicode-regexp */
|
|
2
|
+
import { LexerBuilder } from '@traqula/core';
|
|
3
|
+
import { lex as l11 } from '@traqula/rules-sparql-1-1';
|
|
4
|
+
import { createToken } from '@traqula/core';
|
|
5
|
+
export const tilde = createToken({ name: 'Tilde', pattern: '~', label: '~' });
|
|
6
|
+
export const annotationOpen = createToken({ name: 'AnnotationOpen', pattern: '{|', label: `Annotation Open: {|` });
|
|
7
|
+
export const annotationClose = createToken({ name: 'AnnotationClose', pattern: '|}', label: 'Annotation Close |}' });
|
|
8
|
+
export const reificationOpen = createToken({ name: 'ReificationOpen', pattern: '<<', label: 'Reification open <<' });
|
|
9
|
+
export const reificationClose = createToken({ name: 'ReificationClose', pattern: '>>', label: 'Reification close >>' });
|
|
10
|
+
export const tripleTermOpen = createToken({ name: 'TripleTermOpen', pattern: '<<(', label: 'Triple Term Open <<(' });
|
|
11
|
+
export const tripleTermClose = createToken({ name: 'TripleTermClose', pattern: ')>>', label: 'Triple Term Close )>>' });
|
|
12
|
+
export const builtinLangDir = createToken({ name: 'BuiltInLangdir', pattern: /langdir/i, label: 'LANGDIR' });
|
|
13
|
+
export const builtinStrLangDir = createToken({
|
|
14
|
+
name: 'BuiltInStrLangdir',
|
|
15
|
+
pattern: /strlangdir/i,
|
|
16
|
+
label: 'STRLANGDIR',
|
|
17
|
+
});
|
|
18
|
+
export const builtinHasLang = createToken({ name: 'BuiltInHasLang', pattern: /haslang/i, label: 'hasLANG' });
|
|
19
|
+
export const builtinHasLangDir = createToken({
|
|
20
|
+
name: 'BuiltInHasLangdir',
|
|
21
|
+
pattern: /haslangdir/i,
|
|
22
|
+
label: 'hasLANGDIR',
|
|
23
|
+
});
|
|
24
|
+
export const builtinIsTRIPLE = createToken({ name: 'BuiltInIsTriple', pattern: /istriple/i, label: 'isTRIPLE' });
|
|
25
|
+
export const builtinTRIPLE = createToken({ name: 'BuiltInTriple', pattern: /triple/i, label: 'TRIPLE' });
|
|
26
|
+
export const builtinSUBJECT = createToken({ name: 'BuiltInSubject', pattern: /subject/i, label: 'SUBJECT' });
|
|
27
|
+
export const builtinPREDICATE = createToken({ name: 'BuiltInPredicate', pattern: /predicate/i, label: 'PREDICATE' });
|
|
28
|
+
export const builtinOBJECT = createToken({ name: 'BuiltInObject', pattern: /object/i, label: 'OBJECT' });
|
|
29
|
+
export const LANG_DIR = createToken({
|
|
30
|
+
name: 'LANG_DIR',
|
|
31
|
+
pattern: /@[A-Za-z]+(?:-[\dA-Za-z]+)*(?:--[A-Za-z]+)?/,
|
|
32
|
+
label: 'LANG_DIR',
|
|
33
|
+
});
|
|
34
|
+
export const sparql12Tokens = LexerBuilder
|
|
35
|
+
.create(l11.sparql11Tokens)
|
|
36
|
+
.addBefore(l11.symbols.logicAnd, tilde, annotationOpen, annotationClose, tripleTermOpen, tripleTermClose, reificationOpen, reificationClose)
|
|
37
|
+
.addBefore(l11.builtIn.langmatches, builtinLangDir, builtinStrLangDir, builtinHasLangDir, builtinHasLang, builtinIsTRIPLE, builtinTRIPLE, builtinSUBJECT, builtinPREDICATE, builtinOBJECT)
|
|
38
|
+
.addBefore(l11.terminals.langTag, LANG_DIR)
|
|
39
|
+
.delete(l11.terminals.langTag);
|
|
40
|
+
//# sourceMappingURL=lexer.js.map
|
package/lib/lexer.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lexer.js","sourceRoot":"","sources":["lexer.ts"],"names":[],"mappings":"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","sourcesContent":["/* eslint-disable require-unicode-regexp */\nimport { LexerBuilder } from '@traqula/core';\nimport { lex as l11 } from '@traqula/rules-sparql-1-1';\nimport { createToken } from '@traqula/core';\n\nexport const tilde = createToken({ name: 'Tilde', pattern: '~', label: '~' });\nexport const annotationOpen = createToken({ name: 'AnnotationOpen', pattern: '{|', label: `Annotation Open: {|` });\nexport const annotationClose = createToken({ name: 'AnnotationClose', pattern: '|}', label: 'Annotation Close |}' });\nexport const reificationOpen = createToken({ name: 'ReificationOpen', pattern: '<<', label: 'Reification open <<' });\nexport const reificationClose = createToken({ name: 'ReificationClose', pattern: '>>', label: 'Reification close >>' });\nexport const tripleTermOpen = createToken({ name: 'TripleTermOpen', pattern: '<<(', label: 'Triple Term Open <<(' });\nexport const tripleTermClose = createToken({ name: 'TripleTermClose', pattern: ')>>', label: 'Triple Term Close )>>' });\n\nexport const builtinLangDir = createToken({ name: 'BuiltInLangdir', pattern: /langdir/i, label: 'LANGDIR' });\nexport const builtinStrLangDir = createToken({\n name: 'BuiltInStrLangdir',\n pattern: /strlangdir/i,\n label: 'STRLANGDIR',\n});\nexport const builtinHasLang = createToken({ name: 'BuiltInHasLang', pattern: /haslang/i, label: 'hasLANG' });\nexport const builtinHasLangDir = createToken({\n name: 'BuiltInHasLangdir',\n pattern: /haslangdir/i,\n label: 'hasLANGDIR',\n});\nexport const builtinIsTRIPLE = createToken({ name: 'BuiltInIsTriple', pattern: /istriple/i, label: 'isTRIPLE' });\nexport const builtinTRIPLE = createToken({ name: 'BuiltInTriple', pattern: /triple/i, label: 'TRIPLE' });\nexport const builtinSUBJECT = createToken({ name: 'BuiltInSubject', pattern: /subject/i, label: 'SUBJECT' });\nexport const builtinPREDICATE = createToken({ name: 'BuiltInPredicate', pattern: /predicate/i, label: 'PREDICATE' });\nexport const builtinOBJECT = createToken({ name: 'BuiltInObject', pattern: /object/i, label: 'OBJECT' });\n\nexport const LANG_DIR = createToken({\n name: 'LANG_DIR',\n pattern: /@[A-Za-z]+(?:-[\\dA-Za-z]+)*(?:--[A-Za-z]+)?/,\n label: 'LANG_DIR',\n});\n\nexport const sparql12Tokens = LexerBuilder\n .create(l11.sparql11Tokens)\n .addBefore(\n l11.symbols.logicAnd,\n tilde,\n annotationOpen,\n annotationClose,\n tripleTermOpen,\n tripleTermClose,\n reificationOpen,\n reificationClose,\n )\n .addBefore(\n l11.builtIn.langmatches,\n builtinLangDir,\n builtinStrLangDir,\n builtinHasLangDir,\n builtinHasLang,\n builtinIsTRIPLE,\n builtinTRIPLE,\n builtinSUBJECT,\n builtinPREDICATE,\n builtinOBJECT,\n )\n .addBefore(l11.terminals.langTag, LANG_DIR)\n .delete(l11.terminals.langTag);\n"]}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type * as RdfJs from '@rdfjs/types';
|
|
2
|
+
import type * as T11 from '@traqula/rules-sparql-1-1';
|
|
3
|
+
export type BaseQuadTerm = RdfJs.BaseQuad;
|
|
4
|
+
export type GraphTerm = T11.GraphTerm | BaseQuadTerm;
|
|
5
|
+
export type Term = T11.Term | BaseQuadTerm;
|
|
6
|
+
export type Expression = T11.Expression | BaseQuadTerm;
|
|
7
|
+
export type Triple = {
|
|
8
|
+
subject: Term;
|
|
9
|
+
predicate: T11.IriTerm | T11.VariableTerm | T11.PropertyPath;
|
|
10
|
+
object: Term;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* OVERRIDES: {@link T11.TripleCreatorS}
|
|
14
|
+
*/
|
|
15
|
+
export type TripleCreatorS = (part: Pick<Triple, 'subject'>) => Triple;
|
|
16
|
+
/**
|
|
17
|
+
* OVERRIDES: {@link T11.TripleCreatorSP}
|
|
18
|
+
*/
|
|
19
|
+
export type TripleCreatorSP = (part: Pick<Triple, 'subject' | 'predicate'>) => Triple;
|
|
20
|
+
/**
|
|
21
|
+
* OVERRIDES: {@link T11.ITriplesNode}
|
|
22
|
+
*/
|
|
23
|
+
export interface ITriplesNode {
|
|
24
|
+
node: T11.IriTerm | T11.BlankTerm;
|
|
25
|
+
triples: Triple[];
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* OVERRIDES: {@link T11.IGraphNode}
|
|
29
|
+
*/
|
|
30
|
+
export interface IGraphNode {
|
|
31
|
+
node: ITriplesNode['node'] | Term;
|
|
32
|
+
triples: Triple[];
|
|
33
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sparql12Types.js","sourceRoot":"","sources":["sparql12Types.ts"],"names":[],"mappings":"","sourcesContent":["import type * as RdfJs from '@rdfjs/types';\nimport type * as T11 from '@traqula/rules-sparql-1-1';\n\nexport type BaseQuadTerm = RdfJs.BaseQuad;\nexport type GraphTerm = T11.GraphTerm | BaseQuadTerm;\nexport type Term = T11.Term | BaseQuadTerm;\nexport type Expression = T11.Expression | BaseQuadTerm;\n\nexport type Triple = {\n subject: Term;\n predicate: T11.IriTerm | T11.VariableTerm | T11.PropertyPath;\n object: Term;\n};\n\n/**\n * OVERRIDES: {@link T11.TripleCreatorS}\n */\nexport type TripleCreatorS = (part: Pick<Triple, 'subject'>) => Triple;\n/**\n * OVERRIDES: {@link T11.TripleCreatorSP}\n */\nexport type TripleCreatorSP = (part: Pick<Triple, 'subject' | 'predicate'>) => Triple;\n\n/**\n * OVERRIDES: {@link T11.ITriplesNode}\n */\nexport interface ITriplesNode {\n node: T11.IriTerm | T11.BlankTerm;\n triples: Triple[];\n}\n\n/**\n * OVERRIDES: {@link T11.IGraphNode}\n */\nexport interface IGraphNode {\n node: ITriplesNode['node'] | Term;\n triples: Triple[];\n}\n"]}
|
package/package.json
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@traqula/rules-sparql-1-2",
|
|
3
|
+
"version": "0.0.1-alpha.137+3a4c48f",
|
|
4
|
+
"description": "TRAQULA Lexer and Grammar Rules for sparql 1.2",
|
|
5
|
+
"lsd:module": true,
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"repository": {
|
|
8
|
+
"type": "git",
|
|
9
|
+
"url": "git+https://github.com/comunica/traqula.git",
|
|
10
|
+
"directory": "packages/rules-sparql-1-2"
|
|
11
|
+
},
|
|
12
|
+
"bugs": {
|
|
13
|
+
"url": "https://github.com/comunica/traqula/issues"
|
|
14
|
+
},
|
|
15
|
+
"sideEffects": false,
|
|
16
|
+
"publishConfig": {
|
|
17
|
+
"access": "public"
|
|
18
|
+
},
|
|
19
|
+
"files": [
|
|
20
|
+
"lib/**/*.d.ts",
|
|
21
|
+
"lib/**/*.js",
|
|
22
|
+
"lib/**/*.cjs",
|
|
23
|
+
"lib/**/*.js.map"
|
|
24
|
+
],
|
|
25
|
+
"engines": {
|
|
26
|
+
"node": ">=18.0"
|
|
27
|
+
},
|
|
28
|
+
"typings": "lib/index",
|
|
29
|
+
"type": "module",
|
|
30
|
+
"main": "lib/lexer.js",
|
|
31
|
+
"exports": {
|
|
32
|
+
"import": "./lib/index.js",
|
|
33
|
+
"require": "./lib/index.cjs"
|
|
34
|
+
},
|
|
35
|
+
"scripts": {
|
|
36
|
+
"build": "yarn build:ts && yarn build:transpile",
|
|
37
|
+
"build:ts": "node \"../../node_modules/typescript/bin/tsc\"",
|
|
38
|
+
"build:transpile": " node \"../../node_modules/esbuild/bin/esbuild\" --format=cjs --bundle --log-level=error --outfile=lib/index.cjs lib/index.ts"
|
|
39
|
+
},
|
|
40
|
+
"dependencies": {
|
|
41
|
+
"@traqula/core": "^0.0.1-alpha.137+3a4c48f",
|
|
42
|
+
"@traqula/rules-sparql-1-1": "^0.0.1-alpha.137+3a4c48f",
|
|
43
|
+
"rdf-data-factory": "^2.0.1"
|
|
44
|
+
},
|
|
45
|
+
"gitHead": "3a4c48fd219306b10726fb018b5a1f0ac2abed81"
|
|
46
|
+
}
|