@shaclmate/compiler 4.0.88 → 4.0.89
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/dist/generators/ts/AbstractDateType.d.ts +3 -0
- package/dist/generators/ts/AbstractDateType.js +3 -0
- package/dist/generators/ts/AbstractPrimitiveType.d.ts +5 -0
- package/dist/generators/ts/AbstractPrimitiveType.js +5 -0
- package/dist/generators/ts/BigDecimalType.d.ts +3 -0
- package/dist/generators/ts/BigDecimalType.js +3 -0
- package/package.json +9 -9
|
@@ -3,6 +3,9 @@ import { AbstractTypedLiteralType } from "./AbstractTypedLiteralType.js";
|
|
|
3
3
|
import { type Code } from "./ts-poet-wrapper.js";
|
|
4
4
|
export declare abstract class AbstractDateType extends AbstractTypedLiteralType<Date> {
|
|
5
5
|
protected readonly inlineExpression: Code;
|
|
6
|
+
/**
|
|
7
|
+
* Date has no conversion function to avoid source type overlap with other types (e.g., string).
|
|
8
|
+
*/
|
|
6
9
|
readonly conversionFunction: Maybe<AbstractTypedLiteralType.ConversionFunction>;
|
|
7
10
|
readonly equalsFunction: Code;
|
|
8
11
|
readonly filterFunction: Code;
|
|
@@ -3,6 +3,9 @@ import { AbstractTypedLiteralType } from "./AbstractTypedLiteralType.js";
|
|
|
3
3
|
import { code, literalOf } from "./ts-poet-wrapper.js";
|
|
4
4
|
export class AbstractDateType extends AbstractTypedLiteralType {
|
|
5
5
|
inlineExpression = code `Date`;
|
|
6
|
+
/**
|
|
7
|
+
* Date has no conversion function to avoid source type overlap with other types (e.g., string).
|
|
8
|
+
*/
|
|
6
9
|
conversionFunction = Maybe.empty();
|
|
7
10
|
equalsFunction = code `${this.reusables.snippets.dateEquals}`;
|
|
8
11
|
filterFunction = code `${this.reusables.snippets.filterDate}`;
|
|
@@ -7,6 +7,11 @@ import { type Code } from "./ts-poet-wrapper.js";
|
|
|
7
7
|
* Abstract base class of typed literals whose datatype corresponds to a JavaScript primitive type.
|
|
8
8
|
*/
|
|
9
9
|
export declare abstract class AbstractPrimitiveType<ValueT extends Primitive> extends AbstractTypedLiteralType<ValueT> {
|
|
10
|
+
/**
|
|
11
|
+
* Primitive types have no conversion functions to avoid source type overlap with other primitive types.
|
|
12
|
+
*
|
|
13
|
+
* A property that can take on multiple primitive types should be a union.
|
|
14
|
+
*/
|
|
10
15
|
readonly conversionFunction: Maybe<AbstractLiteralType.ConversionFunction>;
|
|
11
16
|
readonly equalsFunction: Code;
|
|
12
17
|
protected get inlineExpression(): Code;
|
|
@@ -13,6 +13,11 @@ import { arrayOf, code, joinCode } from "./ts-poet-wrapper.js";
|
|
|
13
13
|
* Abstract base class of typed literals whose datatype corresponds to a JavaScript primitive type.
|
|
14
14
|
*/
|
|
15
15
|
export class AbstractPrimitiveType extends AbstractTypedLiteralType {
|
|
16
|
+
/**
|
|
17
|
+
* Primitive types have no conversion functions to avoid source type overlap with other primitive types.
|
|
18
|
+
*
|
|
19
|
+
* A property that can take on multiple primitive types should be a union.
|
|
20
|
+
*/
|
|
16
21
|
conversionFunction = Maybe.empty();
|
|
17
22
|
equalsFunction = code `${this.reusables.snippets.strictEquals}`;
|
|
18
23
|
get inlineExpression() {
|
|
@@ -6,6 +6,9 @@ import { AbstractTypedLiteralType } from "./AbstractTypedLiteralType.js";
|
|
|
6
6
|
import { type Code } from "./ts-poet-wrapper.js";
|
|
7
7
|
export declare class BigDecimalType extends AbstractTypedLiteralType<Decimal> {
|
|
8
8
|
protected readonly inlineExpression: Code;
|
|
9
|
+
/**
|
|
10
|
+
* BigDecimal has no conversion function to avoid source type overlap with other types (e.g., string).
|
|
11
|
+
*/
|
|
9
12
|
readonly conversionFunction: Maybe<AbstractLiteralType.ConversionFunction>;
|
|
10
13
|
readonly filterFunction: Code;
|
|
11
14
|
readonly filterType: Code;
|
|
@@ -11,6 +11,9 @@ import { AbstractTypedLiteralType } from "./AbstractTypedLiteralType.js";
|
|
|
11
11
|
import { code, literalOf } from "./ts-poet-wrapper.js";
|
|
12
12
|
export class BigDecimalType extends AbstractTypedLiteralType {
|
|
13
13
|
inlineExpression = code `${this.reusables.imports.BigDecimal}`;
|
|
14
|
+
/**
|
|
15
|
+
* BigDecimal has no conversion function to avoid source type overlap with other types (e.g., string).
|
|
16
|
+
*/
|
|
14
17
|
conversionFunction = Maybe.empty();
|
|
15
18
|
filterFunction = code `${this.reusables.snippets.filterBigDecimal}`;
|
|
16
19
|
filterType = code `${this.reusables.snippets.NumericFilter}<${this.reusables.imports.BigDecimal}>`;
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"dependencies": {
|
|
3
|
-
"@shaclmate/shacl-ast": "4.0.
|
|
3
|
+
"@shaclmate/shacl-ast": "4.0.89",
|
|
4
4
|
"@rdfjs/types": "~2.0.1",
|
|
5
|
-
"@rdfx/collection": "0.0.
|
|
6
|
-
"@rdfx/data-factory": "0.0.
|
|
7
|
-
"@rdfx/literal": "0.0.
|
|
8
|
-
"@rdfx/logger": "0.0.
|
|
9
|
-
"@rdfx/resource": "0.0.
|
|
5
|
+
"@rdfx/collection": "0.0.56",
|
|
6
|
+
"@rdfx/data-factory": "0.0.56",
|
|
7
|
+
"@rdfx/literal": "0.0.56",
|
|
8
|
+
"@rdfx/logger": "0.0.56",
|
|
9
|
+
"@rdfx/resource": "0.0.56",
|
|
10
10
|
"@sindresorhus/base62": "~0.1.0",
|
|
11
11
|
"@tpluscode/rdf-ns-builders": "~4.3.0",
|
|
12
12
|
"change-case": "~5.4.4",
|
|
@@ -19,8 +19,8 @@
|
|
|
19
19
|
"typescript-memoize": "~1.1.1"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
|
-
"@rdfx/fs": "0.0.
|
|
23
|
-
"@rdfx/serializer": "0.0.
|
|
22
|
+
"@rdfx/fs": "0.0.56",
|
|
23
|
+
"@rdfx/serializer": "0.0.56"
|
|
24
24
|
},
|
|
25
25
|
"files": [
|
|
26
26
|
"dist/Compiler.d.ts",
|
|
@@ -733,5 +733,5 @@
|
|
|
733
733
|
},
|
|
734
734
|
"type": "module",
|
|
735
735
|
"types": "./dist/index.d.ts",
|
|
736
|
-
"version": "4.0.
|
|
736
|
+
"version": "4.0.89"
|
|
737
737
|
}
|