@comunica/actor-function-factory-term-lesser-than 4.5.0 → 5.0.0

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/README.md CHANGED
@@ -24,7 +24,7 @@ After installing, this package can be added to your engine's configuration as fo
24
24
  {
25
25
  "@context": [
26
26
  ...
27
- "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-function-factory-term-lesser-than/^4.0.0/components/context.jsonld"
27
+ "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-function-factory-term-lesser-than/^5.0.0/components/context.jsonld"
28
28
  ],
29
29
  "actors": [
30
30
  ...
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "@context": [
3
- "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-function-factory-term-lesser-than/^4.0.0/components/context.jsonld",
4
- "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/core/^4.0.0/components/context.jsonld",
5
- "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-function-factory/^4.0.0/components/context.jsonld"
3
+ "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-function-factory-term-lesser-than/^5.0.0/components/context.jsonld",
4
+ "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/core/^5.0.0/components/context.jsonld",
5
+ "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/bus-function-factory/^5.0.0/components/context.jsonld"
6
6
  ],
7
7
  "@id": "npmd:@comunica/actor-function-factory-term-lesser-than",
8
8
  "components": [
@@ -39,37 +39,37 @@
39
39
  "genericTypeInstances": [
40
40
  {
41
41
  "@type": "ParameterRangeGenericTypeReference",
42
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_I"
42
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_I"
43
43
  },
44
44
  {
45
45
  "@type": "ParameterRangeGenericTypeReference",
46
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_T"
46
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_T"
47
47
  },
48
48
  {
49
49
  "@type": "ParameterRangeGenericTypeReference",
50
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_O"
50
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_O"
51
51
  },
52
52
  {
53
53
  "@type": "ParameterRangeGenericTypeReference",
54
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_TS"
54
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_TS"
55
55
  }
56
56
  ]
57
57
  },
58
58
  {
59
59
  "@type": "ParameterRangeGenericTypeReference",
60
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_I"
60
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_I"
61
61
  },
62
62
  {
63
63
  "@type": "ParameterRangeGenericTypeReference",
64
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_T"
64
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_T"
65
65
  },
66
66
  {
67
67
  "@type": "ParameterRangeGenericTypeReference",
68
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_O"
68
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_O"
69
69
  },
70
70
  {
71
71
  "@type": "ParameterRangeGenericTypeReference",
72
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_TS"
72
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_TS"
73
73
  }
74
74
  ]
75
75
  },
@@ -106,19 +106,19 @@
106
106
  "genericTypeInstances": [
107
107
  {
108
108
  "@type": "ParameterRangeGenericTypeReference",
109
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_I"
109
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_I"
110
110
  },
111
111
  {
112
112
  "@type": "ParameterRangeGenericTypeReference",
113
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_T"
113
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_T"
114
114
  },
115
115
  {
116
116
  "@type": "ParameterRangeGenericTypeReference",
117
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_O"
117
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_O"
118
118
  },
119
119
  {
120
120
  "@type": "ParameterRangeGenericTypeReference",
121
- "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^4.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_TS"
121
+ "parameterRangeGenericType": "npmd:@comunica/actor-abstract-mediatyped/^5.0.0/components/ActorAbstractMediaTyped.jsonld#ActorAbstractMediaTyped__generic_TS"
122
122
  }
123
123
  ]
124
124
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "@context": [
3
- "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-function-factory-term-lesser-than/^4.0.0/components/context.jsonld"
3
+ "https://linkedsoftwaredependencies.org/bundles/npm/@comunica/actor-function-factory-term-lesser-than/^5.0.0/components/context.jsonld"
4
4
  ],
5
5
  "@id": "npmd:@comunica/actor-function-factory-term-lesser-than",
6
6
  "@type": "Module",
@@ -3,7 +3,7 @@
3
3
  "https://linkedsoftwaredependencies.org/bundles/npm/componentsjs/^6.0.0/components/context.jsonld",
4
4
  {
5
5
  "npmd": "https://linkedsoftwaredependencies.org/bundles/npm/",
6
- "cafftlt": "npmd:@comunica/actor-function-factory-term-lesser-than/^4.0.0/",
6
+ "cafftlt": "npmd:@comunica/actor-function-factory-term-lesser-than/^5.0.0/",
7
7
  "ActorFunctionFactoryTermLesserThan": {
8
8
  "@id": "cafftlt:components/ActorFunctionFactoryTermLesserThan.jsonld#ActorFunctionFactoryTermLesserThan",
9
9
  "@prefix": true,
File without changes
@@ -8,6 +8,7 @@ const TermFunctionLesserThan_1 = require("./TermFunctionLesserThan");
8
8
  * A comunica TermFunctionLesserThan Function Factory Actor.
9
9
  */
10
10
  class ActorFunctionFactoryTermLesserThan extends bus_function_factory_1.ActorFunctionFactoryDedicated {
11
+ mediatorFunctionFactory;
11
12
  constructor(args) {
12
13
  super({
13
14
  ...args,
@@ -1 +1 @@
1
- {"version":3,"file":"ActorFunctionFactoryTermLesserThan.js","sourceRoot":"","sources":["ActorFunctionFactoryTermLesserThan.ts"],"names":[],"mappings":";;;AAQA,yEAEwC;AAExC,qFAAsE;AACtE,qEAAkE;AAMlE;;GAEG;AACH,MAAa,kCAAmC,SAAQ,oDAA6B;IAGnF,YAAmB,IAAqD;QACtE,KAAK,CAAC;YACJ,GAAG,IAAI;YACP,aAAa,EAAE,CAAE,2CAAc,CAAC,EAAE,CAAE;YACpC,YAAY,EAAE,IAAI;SACnB,CAAC,CAAC;QACH,IAAI,CAAC,uBAAuB,GAA6B,IAAI,CAAC,uBAAuB,CAAC;IACxF,CAAC;IAEM,KAAK,CAAC,GAAG,CAAmC,IAAO;QAExD,MAAM,gBAAgB,GAAG,MAAM,IAAI,CAAC,uBAAuB,CAAC,OAAO,CAAC;YAClE,YAAY,EAAE,2CAAc,CAAC,KAAK;YAClC,qBAAqB,EAAE,IAAI;YAC3B,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,SAAS,EAAE,IAAI,CAAC,SAAS;SAC1B,CAAC,CAAC;QACH,OAAO,IAAI,+CAAsB,CAAC,gBAAgB,CAAC,CAAC;IACtD,CAAC;CACF;AAtBD,gFAsBC","sourcesContent":["import type {\n IActionFunctionFactory,\n IActorFunctionFactoryArgs,\n IActorFunctionFactoryOutput,\n IActorFunctionFactoryOutputTerm,\n MediatorFunctionFactoryUnsafe,\n MediatorFunctionFactory,\n} from '@comunica/bus-function-factory';\nimport {\n ActorFunctionFactoryDedicated,\n} from '@comunica/bus-function-factory';\n\nimport { SparqlOperator } from '@comunica/utils-expression-evaluator';\nimport { TermFunctionLesserThan } from './TermFunctionLesserThan';\n\ninterface IActorFunctionFactoryTermFunctionLesserThanArgs extends IActorFunctionFactoryArgs {\n mediatorFunctionFactory: MediatorFunctionFactoryUnsafe;\n}\n\n/**\n * A comunica TermFunctionLesserThan Function Factory Actor.\n */\nexport class ActorFunctionFactoryTermLesserThan extends ActorFunctionFactoryDedicated {\n private readonly mediatorFunctionFactory: MediatorFunctionFactory;\n\n public constructor(args: IActorFunctionFactoryTermFunctionLesserThanArgs) {\n super({\n ...args,\n functionNames: [ SparqlOperator.LT ],\n termFunction: true,\n });\n this.mediatorFunctionFactory = <MediatorFunctionFactory> args.mediatorFunctionFactory;\n }\n\n public async run<T extends IActionFunctionFactory>(args: T):\n Promise<T extends { requireTermExpression: true } ? IActorFunctionFactoryOutputTerm : IActorFunctionFactoryOutput> {\n const equalityFunction = await this.mediatorFunctionFactory.mediate({\n functionName: SparqlOperator.EQUAL,\n requireTermExpression: true,\n context: args.context,\n arguments: args.arguments,\n });\n return new TermFunctionLesserThan(equalityFunction);\n }\n}\n"]}
1
+ {"version":3,"file":"ActorFunctionFactoryTermLesserThan.js","sourceRoot":"","sources":["ActorFunctionFactoryTermLesserThan.ts"],"names":[],"mappings":";;;AAQA,yEAEwC;AAExC,qFAAsE;AACtE,qEAAkE;AAMlE;;GAEG;AACH,MAAa,kCAAmC,SAAQ,oDAA6B;IAClE,uBAAuB,CAA0B;IAElE,YAAmB,IAAqD;QACtE,KAAK,CAAC;YACJ,GAAG,IAAI;YACP,aAAa,EAAE,CAAE,2CAAc,CAAC,EAAE,CAAE;YACpC,YAAY,EAAE,IAAI;SACnB,CAAC,CAAC;QACH,IAAI,CAAC,uBAAuB,GAA6B,IAAI,CAAC,uBAAuB,CAAC;IACxF,CAAC;IAEM,KAAK,CAAC,GAAG,CAAmC,IAAO;QAExD,MAAM,gBAAgB,GAAG,MAAM,IAAI,CAAC,uBAAuB,CAAC,OAAO,CAAC;YAClE,YAAY,EAAE,2CAAc,CAAC,KAAK;YAClC,qBAAqB,EAAE,IAAI;YAC3B,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,SAAS,EAAE,IAAI,CAAC,SAAS;SAC1B,CAAC,CAAC;QACH,OAAO,IAAI,+CAAsB,CAAC,gBAAgB,CAAC,CAAC;IACtD,CAAC;CACF;AAtBD,gFAsBC","sourcesContent":["import type {\n IActionFunctionFactory,\n IActorFunctionFactoryArgs,\n IActorFunctionFactoryOutput,\n IActorFunctionFactoryOutputTerm,\n MediatorFunctionFactoryUnsafe,\n MediatorFunctionFactory,\n} from '@comunica/bus-function-factory';\nimport {\n ActorFunctionFactoryDedicated,\n} from '@comunica/bus-function-factory';\n\nimport { SparqlOperator } from '@comunica/utils-expression-evaluator';\nimport { TermFunctionLesserThan } from './TermFunctionLesserThan';\n\ninterface IActorFunctionFactoryTermFunctionLesserThanArgs extends IActorFunctionFactoryArgs {\n mediatorFunctionFactory: MediatorFunctionFactoryUnsafe;\n}\n\n/**\n * A comunica TermFunctionLesserThan Function Factory Actor.\n */\nexport class ActorFunctionFactoryTermLesserThan extends ActorFunctionFactoryDedicated {\n private readonly mediatorFunctionFactory: MediatorFunctionFactory;\n\n public constructor(args: IActorFunctionFactoryTermFunctionLesserThanArgs) {\n super({\n ...args,\n functionNames: [ SparqlOperator.LT ],\n termFunction: true,\n });\n this.mediatorFunctionFactory = <MediatorFunctionFactory> args.mediatorFunctionFactory;\n }\n\n public async run<T extends IActionFunctionFactory>(args: T):\n Promise<T extends { requireTermExpression: true } ? IActorFunctionFactoryOutputTerm : IActorFunctionFactoryOutput> {\n const equalityFunction = await this.mediatorFunctionFactory.mediate({\n functionName: SparqlOperator.EQUAL,\n requireTermExpression: true,\n context: args.context,\n arguments: args.arguments,\n });\n return new TermFunctionLesserThan(equalityFunction);\n }\n}\n"]}
File without changes
@@ -5,6 +5,7 @@ const bus_function_factory_1 = require("@comunica/bus-function-factory");
5
5
  const context_entries_1 = require("@comunica/context-entries");
6
6
  const utils_expression_evaluator_1 = require("@comunica/utils-expression-evaluator");
7
7
  class TermFunctionLesserThan extends bus_function_factory_1.TermFunctionBase {
8
+ equalityFunction;
8
9
  constructor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gB,CAAC,YAAY,CACvD,CAAE,IAAI,EAAE,KAAK,CAAE,EACf,QAAQ,CACT,CAAC;QACF,IAAsB,cAAe,CAAC,UAAU,EAAE,CAAC;YACjD,OAAO,SAAS,CAAC;QACnB,CAAC;QAED,MAAM,aAAa,GAAG,IAAI,CAAC,YAAY,CACrC,CAAE,IAAI,EAAE,KAAK,CAAE,EACf,QAAQ,CACT,CAAC;QACF,OAAwB,aAAc,CAAC,UAAU,CAAC;IACpD,CAAC;CACF;AA/ED,wDA+EC","sourcesContent":["import type { ITermFunction } from '@comunica/bus-function-factory';\nimport { TermFunctionBase } from '@comunica/bus-function-factory';\nimport { KeysExpressionEvaluator } from '@comunica/context-entries';\nimport type { IInternalEvaluator } from '@comunica/types';\nimport type {\n BooleanLiteral,\n Term,\n DayTimeDurationLiteral,\n Quad,\n TimeLiteral,\n YearMonthDurationLiteral,\n} from '@comunica/utils-expression-evaluator';\nimport {\n bool,\n dayTimeDurationsToSeconds,\n declare,\n defaultedDateTimeRepresentation,\n defaultedDayTimeDurationRepresentation,\n defaultedYearMonthDurationRepresentation,\n SparqlOperator,\n toUTCDate,\n TypeURL,\n yearMonthDurationsToMonths,\n} from '@comunica/utils-expression-evaluator';\n\nexport class TermFunctionLesserThan extends TermFunctionBase {\n public constructor(private readonly equalityFunction: ITermFunction) {\n super({\n arity: 2,\n operator: SparqlOperator.LT,\n overloads: declare(SparqlOperator.LT)\n .numberTest(() => (left, right) => left < right)\n .stringTest(() => (left, right) => left.localeCompare(right) === -1)\n .booleanTest(() => (left, right) => left < right)\n .dateTimeTest(exprEval => (left, right) =>\n toUTCDate(left, exprEval.context.getSafe(KeysExpressionEvaluator.defaultTimeZone)).getTime() <\n toUTCDate(right, exprEval.context.getSafe(KeysExpressionEvaluator.defaultTimeZone)).getTime())\n .copy({\n // https://www.w3.org/TR/xpath-functions/#func-date-less-than\n from: [ TypeURL.XSD_DATE_TIME, TypeURL.XSD_DATE_TIME ],\n to: [ TypeURL.XSD_DATE, TypeURL.XSD_DATE ],\n })\n .set([ TypeURL.XSD_YEAR_MONTH_DURATION, TypeURL.XSD_YEAR_MONTH_DURATION ], () =>\n ([ dur1L, dur2L ]: [YearMonthDurationLiteral, YearMonthDurationLiteral]) =>\n // https://www.w3.org/TR/xpath-functions/#func-yearMonthDuration-less-than\n bool(yearMonthDurationsToMonths(defaultedYearMonthDurationRepresentation(dur1L.typedValue)) <\n yearMonthDurationsToMonths(defaultedYearMonthDurationRepresentation(dur2L.typedValue))))\n .set([ TypeURL.XSD_DAY_TIME_DURATION, TypeURL.XSD_DAY_TIME_DURATION ], () =>\n ([ dur1, dur2 ]: [DayTimeDurationLiteral, DayTimeDurationLiteral]) =>\n // https://www.w3.org/TR/xpath-functions/#func-dayTimeDuration-greater-than\n bool(dayTimeDurationsToSeconds(defaultedDayTimeDurationRepresentation(dur1.typedValue)) <\n dayTimeDurationsToSeconds(defaultedDayTimeDurationRepresentation(dur2.typedValue))))\n .set([ TypeURL.XSD_TIME, TypeURL.XSD_TIME ], exprEval =>\n ([ time1, time2 ]: [TimeLiteral, TimeLiteral]) =>\n // https://www.w3.org/TR/xpath-functions/#func-time-less-than\n bool(\n toUTCDate(\n defaultedDateTimeRepresentation(time1.typedValue),\n exprEval.context.getSafe(KeysExpressionEvaluator.defaultTimeZone),\n ).getTime() <\n toUTCDate(\n defaultedDateTimeRepresentation(time2.typedValue),\n exprEval.context.getSafe(KeysExpressionEvaluator.defaultTimeZone),\n ).getTime(),\n ))\n .set(\n [ 'quad', 'quad' ],\n exprEval => ([ left, right ]: [Quad, Quad]) => {\n const subjectTest = this.quadComponentTest(left.subject, right.subject, exprEval);\n if (subjectTest !== undefined) {\n return bool(subjectTest);\n }\n const predicateTest = this.quadComponentTest(left.predicate, right.predicate, exprEval);\n if (predicateTest !== undefined) {\n return bool(predicateTest);\n }\n const objectTest = this.quadComponentTest(left.object, right.object, exprEval);\n if (objectTest !== undefined) {\n return bool(objectTest);\n }\n return bool(this.quadComponentTest(left.graph, right.graph, exprEval) ?? false);\n },\n false,\n )\n .collect(),\n });\n }\n\n private quadComponentTest(left: Term, right: Term, exprEval: IInternalEvaluator): boolean | undefined {\n // If components are equal, we don't have an answer\n const componentEqual = this.equalityFunction.applyOnTerms(\n [ left, right ],\n exprEval,\n );\n if ((<BooleanLiteral> componentEqual).typedValue) {\n return undefined;\n }\n\n const componentLess = this.applyOnTerms(\n [ left, right ],\n exprEval,\n );\n return (<BooleanLiteral>componentLess).typedValue;\n }\n}\n"]}
1
+ {"version":3,"file":"TermFunctionLesserThan.js","sourceRoot":"","sources":["TermFunctionLesserThan.ts"],"names":[],"mappings":";;;AACA,yEAAkE;AAClE,+DAAoE;AAUpE,qFAW8C;AAE9C,MAAa,sBAAuB,SAAQ,uCAAgB;IACtB;IAApC,YAAoC,gBAA+B;QACjE,KAAK,CAAC;YACJ,KAAK,EAAE,CAAC;YACR,QAAQ,EAAE,2CAAc,CAAC,EAAE;YAC3B,SAAS,EAAE,IAAA,oCAAO,EAAC,2CAAc,CAAC,EAAE,CAAC;iBAClC,UAAU,CAAC,GAAG,EAAE,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,CAAC,IAAI,GAAG,KAAK,CAAC;iBAC/C,UAAU,CAAC,GAAG,EAAE,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,CAAC,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC;iBACnE,WAAW,CAAC,GAAG,EAAE,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,CAAC,IAAI,GAAG,KAAK,CAAC;iBAChD,YAAY,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,CACxC,IAAA,sCAAS,EAAC,IAAI,EAAE,QAAQ,CAAC,OAAO,CAAC,OAAO,CAAC,yCAAuB,CAAC,eAAe,CAAC,CAAC,CAAC,OAAO,EAAE;gBAC5F,IAAA,sCAAS,EAAC,KAAK,E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E,QAAQ,CAAC,IAAI,KAAK,CAAC,CAAC;YAClF,CAAC,EACD,KAAK,CACN;iBACA,OAAO,EAAE;SACb,CAAC,CAAC;QA3D+B,qBAAgB,GAAhB,gBAAgB,CAAe;IA4DnE,CAAC;IAEO,iBAAiB,CAAC,IAAU,EAAE,KAAW,EAAE,QAA4B;QAC7E,mDAAmD;QACnD,MAAM,cAAc,GAAG,IAAI,CAAC,gBAAgB,CAAC,YAAY,CACvD,CAAE,IAAI,EAAE,KAAK,CAAE,EACf,QAAQ,CACT,CAAC;QACF,IAAsB,cAAe,CAAC,UAAU,EAAE,CAAC;YACjD,OAAO,SAAS,CAAC;QACnB,CAAC;QAED,MAAM,aAAa,GAAG,IAAI,CAAC,YAAY,CACrC,CAAE,IAAI,EAAE,KAAK,CAAE,EACf,QAAQ,CACT,CAAC;QACF,OAAwB,aAAc,CAAC,UAAU,CAAC;IACpD,CAAC;CACF;AA/ED,wDA+EC","sourcesContent":["import type { ITermFunction } from '@comunica/bus-function-factory';\nimport { TermFunctionBase } from '@comunica/bus-function-factory';\nimport { KeysExpressionEvaluator } from '@comunica/context-entries';\nimport type { IInternalEvaluator } from '@comunica/types';\nimport type {\n BooleanLiteral,\n Term,\n DayTimeDurationLiteral,\n Quad,\n TimeLiteral,\n YearMonthDurationLiteral,\n} from '@comunica/utils-expression-evaluator';\nimport {\n bool,\n dayTimeDurationsToSeconds,\n declare,\n defaultedDateTimeRepresentation,\n defaultedDayTimeDurationRepresentation,\n defaultedYearMonthDurationRepresentation,\n SparqlOperator,\n toUTCDate,\n TypeURL,\n yearMonthDurationsToMonths,\n} from '@comunica/utils-expression-evaluator';\n\nexport class TermFunctionLesserThan extends TermFunctionBase {\n public constructor(private readonly equalityFunction: ITermFunction) {\n super({\n arity: 2,\n operator: SparqlOperator.LT,\n overloads: declare(SparqlOperator.LT)\n .numberTest(() => (left, right) => left < right)\n .stringTest(() => (left, right) => left.localeCompare(right) === -1)\n .booleanTest(() => (left, right) => left < right)\n .dateTimeTest(exprEval => (left, right) =>\n toUTCDate(left, exprEval.context.getSafe(KeysExpressionEvaluator.defaultTimeZone)).getTime() <\n toUTCDate(right, exprEval.context.getSafe(KeysExpressionEvaluator.defaultTimeZone)).getTime())\n .copy({\n // https://www.w3.org/TR/xpath-functions/#func-date-less-than\n from: [ TypeURL.XSD_DATE_TIME, TypeURL.XSD_DATE_TIME ],\n to: [ TypeURL.XSD_DATE, TypeURL.XSD_DATE ],\n })\n .set([ TypeURL.XSD_YEAR_MONTH_DURATION, TypeURL.XSD_YEAR_MONTH_DURATION ], () =>\n ([ dur1L, dur2L ]: [YearMonthDurationLiteral, YearMonthDurationLiteral]) =>\n // https://www.w3.org/TR/xpath-functions/#func-yearMonthDuration-less-than\n bool(yearMonthDurationsToMonths(defaultedYearMonthDurationRepresentation(dur1L.typedValue)) <\n yearMonthDurationsToMonths(defaultedYearMonthDurationRepresentation(dur2L.typedValue))))\n .set([ TypeURL.XSD_DAY_TIME_DURATION, TypeURL.XSD_DAY_TIME_DURATION ], () =>\n ([ dur1, dur2 ]: [DayTimeDurationLiteral, DayTimeDurationLiteral]) =>\n // https://www.w3.org/TR/xpath-functions/#func-dayTimeDuration-greater-than\n bool(dayTimeDurationsToSeconds(defaultedDayTimeDurationRepresentation(dur1.typedValue)) <\n dayTimeDurationsToSeconds(defaultedDayTimeDurationRepresentation(dur2.typedValue))))\n .set([ TypeURL.XSD_TIME, TypeURL.XSD_TIME ], exprEval =>\n ([ time1, time2 ]: [TimeLiteral, TimeLiteral]) =>\n // https://www.w3.org/TR/xpath-functions/#func-time-less-than\n bool(\n toUTCDate(\n defaultedDateTimeRepresentation(time1.typedValue),\n exprEval.context.getSafe(KeysExpressionEvaluator.defaultTimeZone),\n ).getTime() <\n toUTCDate(\n defaultedDateTimeRepresentation(time2.typedValue),\n exprEval.context.getSafe(KeysExpressionEvaluator.defaultTimeZone),\n ).getTime(),\n ))\n .set(\n [ 'quad', 'quad' ],\n exprEval => ([ left, right ]: [Quad, Quad]) => {\n const subjectTest = this.quadComponentTest(left.subject, right.subject, exprEval);\n if (subjectTest !== undefined) {\n return bool(subjectTest);\n }\n const predicateTest = this.quadComponentTest(left.predicate, right.predicate, exprEval);\n if (predicateTest !== undefined) {\n return bool(predicateTest);\n }\n const objectTest = this.quadComponentTest(left.object, right.object, exprEval);\n if (objectTest !== undefined) {\n return bool(objectTest);\n }\n return bool(this.quadComponentTest(left.graph, right.graph, exprEval) ?? false);\n },\n false,\n )\n .collect(),\n });\n }\n\n private quadComponentTest(left: Term, right: Term, exprEval: IInternalEvaluator): boolean | undefined {\n // If components are equal, we don't have an answer\n const componentEqual = this.equalityFunction.applyOnTerms(\n [ left, right ],\n exprEval,\n );\n if ((<BooleanLiteral> componentEqual).typedValue) {\n return undefined;\n }\n\n const componentLess = this.applyOnTerms(\n [ left, right ],\n exprEval,\n );\n return (<BooleanLiteral>componentLess).typedValue;\n }\n}\n"]}
package/lib/index.d.ts CHANGED
File without changes
package/lib/index.js CHANGED
File without changes
package/lib/index.js.map CHANGED
File without changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@comunica/actor-function-factory-term-lesser-than",
3
- "version": "4.5.0",
3
+ "version": "5.0.0",
4
4
  "description": "A term-lesser-than function-factory actor",
5
5
  "lsd:module": true,
6
6
  "license": "MIT",
@@ -37,9 +37,9 @@
37
37
  "build:components": "componentsjs-generator"
38
38
  },
39
39
  "dependencies": {
40
- "@comunica/bus-function-factory": "^4.5.0",
41
- "@comunica/context-entries": "^4.5.0",
42
- "@comunica/utils-expression-evaluator": "^4.5.0"
40
+ "@comunica/bus-function-factory": "^5.0.0",
41
+ "@comunica/context-entries": "^5.0.0",
42
+ "@comunica/utils-expression-evaluator": "^5.0.0"
43
43
  },
44
- "gitHead": "2bcd98c387a021fc5c08d375793c205ca3d1bf0d"
44
+ "gitHead": "0b1756fdb9bef014133432489627c1bd71779bd0"
45
45
  }