@skmtc/core 0.0.381 → 0.0.383
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/esm/context/CoreContext.d.ts +2 -2
- package/esm/context/CoreContext.d.ts.map +1 -1
- package/esm/context/GenerateContext.d.ts +46 -14
- package/esm/context/GenerateContext.d.ts.map +1 -1
- package/esm/context/GenerateContext.js +187 -76
- package/esm/context/RenderContext.d.ts +3 -3
- package/esm/context/RenderContext.d.ts.map +1 -1
- package/esm/context/types.d.ts +2 -2
- package/esm/context/types.d.ts.map +1 -1
- package/esm/dsl/GatewayBase.d.ts +12 -0
- package/esm/dsl/GatewayBase.d.ts.map +1 -0
- package/esm/dsl/GatewayBase.js +13 -0
- package/esm/dsl/model/ModelBase.d.ts.map +1 -1
- package/esm/dsl/model/ModelBase.js +1 -1
- package/esm/dsl/model/ModelInsertable.d.ts +10 -5
- package/esm/dsl/model/ModelInsertable.d.ts.map +1 -1
- package/esm/dsl/model/toModelGateway.d.ts +30 -0
- package/esm/dsl/model/toModelGateway.d.ts.map +1 -0
- package/esm/dsl/model/toModelGateway.js +70 -0
- package/esm/dsl/model/toModelInsertable.d.ts +36 -0
- package/esm/dsl/model/toModelInsertable.d.ts.map +1 -0
- package/esm/dsl/model/{toModelBase.js → toModelInsertable.js} +3 -41
- package/esm/dsl/operation/OperationBase.d.ts.map +1 -1
- package/esm/dsl/operation/OperationBase.js +1 -1
- package/esm/dsl/operation/OperationInsertable.d.ts +17 -5
- package/esm/dsl/operation/OperationInsertable.d.ts.map +1 -1
- package/esm/dsl/operation/toOperationGateway.d.ts +32 -0
- package/esm/dsl/operation/toOperationGateway.d.ts.map +1 -0
- package/esm/dsl/operation/toOperationGateway.js +70 -0
- package/esm/dsl/operation/toOperationInsertable.d.ts +43 -0
- package/esm/dsl/operation/toOperationInsertable.d.ts.map +1 -0
- package/esm/dsl/operation/{toOperationBase.js → toOperationInsertable.js} +3 -41
- package/esm/helpers/ResultsLog.d.ts +2 -2
- package/esm/helpers/ResultsLog.d.ts.map +1 -1
- package/esm/helpers/ResultsLog.js +11 -3
- package/esm/mod.d.ts +4 -2
- package/esm/mod.d.ts.map +1 -1
- package/esm/mod.js +4 -2
- package/esm/types/Results.d.ts +3 -3
- package/esm/types/Results.d.ts.map +1 -1
- package/esm/types/Results.js +2 -2
- package/esm/types/Settings.d.ts +24 -12
- package/esm/types/Settings.d.ts.map +1 -1
- package/esm/types/Settings.js +4 -3
- package/package.json +1 -1
- package/script/context/CoreContext.d.ts +2 -2
- package/script/context/CoreContext.d.ts.map +1 -1
- package/script/context/GenerateContext.d.ts +46 -14
- package/script/context/GenerateContext.d.ts.map +1 -1
- package/script/context/GenerateContext.js +187 -76
- package/script/context/RenderContext.d.ts +3 -3
- package/script/context/RenderContext.d.ts.map +1 -1
- package/script/context/types.d.ts +2 -2
- package/script/context/types.d.ts.map +1 -1
- package/script/dsl/GatewayBase.d.ts +12 -0
- package/script/dsl/GatewayBase.d.ts.map +1 -0
- package/script/dsl/{GeneratorBase.js → GatewayBase.js} +6 -4
- package/script/dsl/model/ModelBase.d.ts.map +1 -1
- package/script/dsl/model/ModelBase.js +1 -1
- package/script/dsl/model/ModelInsertable.d.ts +10 -5
- package/script/dsl/model/ModelInsertable.d.ts.map +1 -1
- package/script/dsl/model/toModelGateway.d.ts +30 -0
- package/script/dsl/model/toModelGateway.d.ts.map +1 -0
- package/script/dsl/model/toModelGateway.js +74 -0
- package/script/dsl/model/toModelInsertable.d.ts +36 -0
- package/script/dsl/model/toModelInsertable.d.ts.map +1 -0
- package/script/dsl/model/{toModelBase.js → toModelInsertable.js} +5 -43
- package/script/dsl/operation/OperationBase.d.ts.map +1 -1
- package/script/dsl/operation/OperationBase.js +1 -1
- package/script/dsl/operation/OperationInsertable.d.ts +17 -5
- package/script/dsl/operation/OperationInsertable.d.ts.map +1 -1
- package/script/dsl/operation/toOperationGateway.d.ts +32 -0
- package/script/dsl/operation/toOperationGateway.d.ts.map +1 -0
- package/script/dsl/operation/toOperationGateway.js +74 -0
- package/script/dsl/operation/toOperationInsertable.d.ts +43 -0
- package/script/dsl/operation/toOperationInsertable.d.ts.map +1 -0
- package/script/dsl/operation/{toOperationBase.js → toOperationInsertable.js} +5 -43
- package/script/helpers/ResultsLog.d.ts +2 -2
- package/script/helpers/ResultsLog.d.ts.map +1 -1
- package/script/helpers/ResultsLog.js +11 -3
- package/script/mod.d.ts +4 -2
- package/script/mod.d.ts.map +1 -1
- package/script/mod.js +4 -2
- package/script/types/Results.d.ts +3 -3
- package/script/types/Results.d.ts.map +1 -1
- package/script/types/Results.js +3 -3
- package/script/types/Settings.d.ts +24 -12
- package/script/types/Settings.d.ts.map +1 -1
- package/script/types/Settings.js +4 -3
- package/esm/dsl/GeneratorBase.d.ts +0 -6
- package/esm/dsl/GeneratorBase.d.ts.map +0 -1
- package/esm/dsl/GeneratorBase.js +0 -11
- package/esm/dsl/model/toModelBase.d.ts +0 -48
- package/esm/dsl/model/toModelBase.d.ts.map +0 -1
- package/esm/dsl/operation/toOperationBase.d.ts +0 -55
- package/esm/dsl/operation/toOperationBase.d.ts.map +0 -1
- package/script/dsl/GeneratorBase.d.ts +0 -6
- package/script/dsl/GeneratorBase.d.ts.map +0 -1
- package/script/dsl/model/toModelBase.d.ts +0 -48
- package/script/dsl/model/toModelBase.d.ts.map +0 -1
- package/script/dsl/operation/toOperationBase.d.ts +0 -55
- package/script/dsl/operation/toOperationBase.d.ts.map +0 -1
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __setFunctionName = (this && this.__setFunctionName) || function (f, name, prefix) {
|
|
3
|
+
if (typeof name === "symbol") name = name.description ? "[".concat(name.description, "]") : "";
|
|
4
|
+
return Object.defineProperty(f, "name", { configurable: true, value: prefix ? "".concat(prefix, " ", name) : name });
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.toModelGateway = void 0;
|
|
8
|
+
const GatewayBase_js_1 = require("../GatewayBase.js");
|
|
9
|
+
const toModelGateway = (config) => {
|
|
10
|
+
var _a;
|
|
11
|
+
const ModelGateway = (_a = class extends GatewayBase_js_1.GatewayBase {
|
|
12
|
+
constructor({ context, settings }) {
|
|
13
|
+
super({ context, settings });
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
__setFunctionName(_a, "ModelGateway"),
|
|
17
|
+
Object.defineProperty(_a, "id", {
|
|
18
|
+
enumerable: true,
|
|
19
|
+
configurable: true,
|
|
20
|
+
writable: true,
|
|
21
|
+
value: config.id
|
|
22
|
+
}),
|
|
23
|
+
Object.defineProperty(_a, "type", {
|
|
24
|
+
enumerable: true,
|
|
25
|
+
configurable: true,
|
|
26
|
+
writable: true,
|
|
27
|
+
value: 'model'
|
|
28
|
+
}),
|
|
29
|
+
Object.defineProperty(_a, "_class", {
|
|
30
|
+
enumerable: true,
|
|
31
|
+
configurable: true,
|
|
32
|
+
writable: true,
|
|
33
|
+
value: 'ModelGateway'
|
|
34
|
+
}),
|
|
35
|
+
Object.defineProperty(_a, "toIdentifier", {
|
|
36
|
+
enumerable: true,
|
|
37
|
+
configurable: true,
|
|
38
|
+
writable: true,
|
|
39
|
+
value: config.toIdentifier.bind(config)
|
|
40
|
+
}),
|
|
41
|
+
Object.defineProperty(_a, "toExportPath", {
|
|
42
|
+
enumerable: true,
|
|
43
|
+
configurable: true,
|
|
44
|
+
writable: true,
|
|
45
|
+
value: config.toExportPath.bind(config)
|
|
46
|
+
}),
|
|
47
|
+
Object.defineProperty(_a, "isGeneratorSelected", {
|
|
48
|
+
enumerable: true,
|
|
49
|
+
configurable: true,
|
|
50
|
+
writable: true,
|
|
51
|
+
value: config.isGeneratorSelected ?? (() => true)
|
|
52
|
+
}),
|
|
53
|
+
Object.defineProperty(_a, "isModelSelected", {
|
|
54
|
+
enumerable: true,
|
|
55
|
+
configurable: true,
|
|
56
|
+
writable: true,
|
|
57
|
+
value: config.isModelSelected ?? (() => true)
|
|
58
|
+
}),
|
|
59
|
+
Object.defineProperty(_a, "isSupported", {
|
|
60
|
+
enumerable: true,
|
|
61
|
+
configurable: true,
|
|
62
|
+
writable: true,
|
|
63
|
+
value: () => true
|
|
64
|
+
}),
|
|
65
|
+
Object.defineProperty(_a, "pinnable", {
|
|
66
|
+
enumerable: true,
|
|
67
|
+
configurable: true,
|
|
68
|
+
writable: true,
|
|
69
|
+
value: false
|
|
70
|
+
}),
|
|
71
|
+
_a);
|
|
72
|
+
return ModelGateway;
|
|
73
|
+
};
|
|
74
|
+
exports.toModelGateway = toModelGateway;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import type { GenerateContext } from '../../context/GenerateContext.js';
|
|
2
|
+
import type { RefName } from '../../types/RefName.js';
|
|
3
|
+
import type { ContentSettings } from '../ContentSettings.js';
|
|
4
|
+
import type { IsModelSelectedArgs, ToModelExportPathArgs, ToModelIdentifierArgs } from './ModelInsertable.js';
|
|
5
|
+
import type { Identifier } from '../Identifier.js';
|
|
6
|
+
export type ModelInsertableArgs = {
|
|
7
|
+
context: GenerateContext;
|
|
8
|
+
settings: ContentSettings;
|
|
9
|
+
refName: RefName;
|
|
10
|
+
};
|
|
11
|
+
export type ModelConfig = {
|
|
12
|
+
id: string;
|
|
13
|
+
toIdentifier: ({ refName, baseSettings }: ToModelIdentifierArgs) => Identifier;
|
|
14
|
+
toExportPath: ({ refName, baseSettings }: ToModelExportPathArgs) => string;
|
|
15
|
+
isSelected?: ({ refName, baseSettings }: IsModelSelectedArgs) => boolean;
|
|
16
|
+
};
|
|
17
|
+
export declare const toModelInsertable: (config: ModelConfig) => {
|
|
18
|
+
new (args: ModelInsertableArgs): {
|
|
19
|
+
settings: ContentSettings;
|
|
20
|
+
refName: RefName;
|
|
21
|
+
generatorKey: import("../../types/GeneratorKeys.js").GeneratorKey;
|
|
22
|
+
transform<V extends import("../../mod.js").GeneratedValue>(insertable: import("./ModelInsertable.js").ModelInsertable<V>, refName: RefName): import("../Inserted.js").Inserted<V, "force">;
|
|
23
|
+
register(args: Partial<import("../../context/GenerateContext.js").RegisterArgs>): void;
|
|
24
|
+
context: GenerateContext;
|
|
25
|
+
skipped: boolean;
|
|
26
|
+
};
|
|
27
|
+
id: string;
|
|
28
|
+
type: "model";
|
|
29
|
+
_class: "ModelInsertable";
|
|
30
|
+
toIdentifier: ({ refName, baseSettings }: ToModelIdentifierArgs) => Identifier;
|
|
31
|
+
toExportPath: ({ refName, baseSettings }: ToModelExportPathArgs) => string;
|
|
32
|
+
isSelected: ({ refName, baseSettings }: IsModelSelectedArgs) => boolean;
|
|
33
|
+
isSupported: () => boolean;
|
|
34
|
+
pinnable: boolean;
|
|
35
|
+
};
|
|
36
|
+
//# sourceMappingURL=toModelInsertable.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toModelInsertable.d.ts","sourceRoot":"","sources":["../../../src/dsl/model/toModelInsertable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAA;AAEvE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAA;AACrD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAC5D,OAAO,KAAK,EACV,mBAAmB,EACnB,qBAAqB,EACrB,qBAAqB,EACtB,MAAM,sBAAsB,CAAA;AAE7B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAElD,MAAM,MAAM,mBAAmB,GAAG;IAChC,OAAO,EAAE,eAAe,CAAA;IACxB,QAAQ,EAAE,eAAe,CAAA;IACzB,OAAO,EAAE,OAAO,CAAA;CACjB,CAAA;AAED,MAAM,MAAM,WAAW,GAAG;IACxB,EAAE,EAAE,MAAM,CAAA;IACV,YAAY,EAAE,CAAC,EAAE,OAAO,EAAE,YAAY,EAAE,EAAE,qBAAqB,KAAK,UAAU,CAAA;IAC9E,YAAY,EAAE,CAAC,EAAE,OAAO,EAAE,YAAY,EAAE,EAAE,qBAAqB,KAAK,MAAM,CAAA;IAC1E,UAAU,CAAC,EAAE,CAAC,EAAE,OAAO,EAAE,YAAY,EAAE,EAAE,mBAAmB,KAAK,OAAO,CAAA;CACzE,CAAA;AAED,eAAO,MAAM,iBAAiB,WAAY,WAAW;eAc/B,mBAAmB;;;;;;;;;;;;8CAnBG,qBAAqB,KAAK,UAAU;8CACpC,qBAAqB,KAAK,MAAM;4CACjC,mBAAmB,KAAK,OAAO;;;CA6BzE,CAAA"}
|
|
@@ -4,12 +4,11 @@ var __setFunctionName = (this && this.__setFunctionName) || function (f, name, p
|
|
|
4
4
|
return Object.defineProperty(f, "name", { configurable: true, value: prefix ? "".concat(prefix, " ", name) : name });
|
|
5
5
|
};
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
-
exports.
|
|
7
|
+
exports.toModelInsertable = void 0;
|
|
8
8
|
const GeneratorKeys_js_1 = require("../../types/GeneratorKeys.js");
|
|
9
|
-
const GeneratorBase_js_1 = require("../GeneratorBase.js");
|
|
10
9
|
const ModelBase_js_1 = require("./ModelBase.js");
|
|
11
|
-
const
|
|
12
|
-
var _a
|
|
10
|
+
const toModelInsertable = (config) => {
|
|
11
|
+
var _a;
|
|
13
12
|
const ModelInsertable = (_a = class extends ModelBase_js_1.ModelBase {
|
|
14
13
|
constructor(args) {
|
|
15
14
|
super({
|
|
@@ -71,43 +70,6 @@ const toModelBase = (config) => {
|
|
|
71
70
|
value: false
|
|
72
71
|
}),
|
|
73
72
|
_a);
|
|
74
|
-
|
|
75
|
-
constructor(context) {
|
|
76
|
-
super(context);
|
|
77
|
-
}
|
|
78
|
-
},
|
|
79
|
-
__setFunctionName(_b, "ModelGateway"),
|
|
80
|
-
Object.defineProperty(_b, "id", {
|
|
81
|
-
enumerable: true,
|
|
82
|
-
configurable: true,
|
|
83
|
-
writable: true,
|
|
84
|
-
value: config.id
|
|
85
|
-
}),
|
|
86
|
-
Object.defineProperty(_b, "type", {
|
|
87
|
-
enumerable: true,
|
|
88
|
-
configurable: true,
|
|
89
|
-
writable: true,
|
|
90
|
-
value: 'model'
|
|
91
|
-
}),
|
|
92
|
-
Object.defineProperty(_b, "_class", {
|
|
93
|
-
enumerable: true,
|
|
94
|
-
configurable: true,
|
|
95
|
-
writable: true,
|
|
96
|
-
value: 'ModelGateway'
|
|
97
|
-
}),
|
|
98
|
-
Object.defineProperty(_b, "isSupported", {
|
|
99
|
-
enumerable: true,
|
|
100
|
-
configurable: true,
|
|
101
|
-
writable: true,
|
|
102
|
-
value: () => true
|
|
103
|
-
}),
|
|
104
|
-
Object.defineProperty(_b, "pinnable", {
|
|
105
|
-
enumerable: true,
|
|
106
|
-
configurable: true,
|
|
107
|
-
writable: true,
|
|
108
|
-
value: false
|
|
109
|
-
}),
|
|
110
|
-
_b);
|
|
111
|
-
return { ModelInsertable, ModelGateway };
|
|
73
|
+
return ModelInsertable;
|
|
112
74
|
};
|
|
113
|
-
exports.
|
|
75
|
+
exports.toModelInsertable = toModelInsertable;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OperationBase.d.ts","sourceRoot":"","sources":["../../../src/dsl/operation/OperationBase.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAA;AACnE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AACpE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAC5D,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"OperationBase.d.ts","sourceRoot":"","sources":["../../../src/dsl/operation/OperationBase.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAA;AACnE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AACpE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAC5D,OAAO,KAAK,EA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2BAA2B,CAAC,MAAM,CAAC,GAAG,UAAU,CAAC,gBAAgB,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC;IASrF,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC,YAAY,CAAC;CAMrC"}
|
|
@@ -8,7 +8,7 @@ type OperationInsertableConstructorArgs = {
|
|
|
8
8
|
settings: ContentSettings;
|
|
9
9
|
operation: OasOperation;
|
|
10
10
|
};
|
|
11
|
-
export type
|
|
11
|
+
export type ToOperationIdentifierArgs = {
|
|
12
12
|
operation: OasOperation;
|
|
13
13
|
baseSettings: BaseSettings;
|
|
14
14
|
};
|
|
@@ -20,16 +20,28 @@ export type IsOperationSelectedArgs = {
|
|
|
20
20
|
operation: OasOperation;
|
|
21
21
|
baseSettings: BaseSettings;
|
|
22
22
|
};
|
|
23
|
+
export type IsGeneratorSelectedArgs = {
|
|
24
|
+
operation: OasOperation;
|
|
25
|
+
baseSettings: BaseSettings;
|
|
26
|
+
};
|
|
23
27
|
export type WithTransformOperation = {
|
|
24
28
|
transformOperation: (operation: OasOperation) => void;
|
|
25
29
|
};
|
|
30
|
+
export type OperationGatewayConstructorArgs = {
|
|
31
|
+
context: GenerateContext;
|
|
32
|
+
settings: ContentSettings;
|
|
33
|
+
};
|
|
26
34
|
export type OperationGateway = {
|
|
27
|
-
new (context:
|
|
35
|
+
new ({ context, settings }: OperationGatewayConstructorArgs): WithTransformOperation;
|
|
28
36
|
id: string;
|
|
29
37
|
type: 'operation';
|
|
30
38
|
_class: 'OperationGateway';
|
|
31
|
-
|
|
39
|
+
toIdentifier: (baseSettings: BaseSettings) => Identifier;
|
|
40
|
+
toExportPath: (baseSettings: BaseSettings) => string;
|
|
41
|
+
isGeneratorSelected: (baseSettings: BaseSettings) => boolean;
|
|
42
|
+
isOperationSelected: ({ operation, baseSettings }: IsOperationSelectedArgs) => boolean;
|
|
32
43
|
isSupported: (operation: OasOperation) => boolean;
|
|
44
|
+
pinnable: boolean;
|
|
33
45
|
};
|
|
34
46
|
export type OperationInsertable<V> = {
|
|
35
47
|
prototype: V;
|
|
@@ -38,11 +50,11 @@ export type OperationInsertable<V> = {
|
|
|
38
50
|
id: string;
|
|
39
51
|
type: 'operation';
|
|
40
52
|
_class: 'OperationInsertable';
|
|
41
|
-
toIdentifier: ({ operation, baseSettings }:
|
|
53
|
+
toIdentifier: ({ operation, baseSettings }: ToOperationIdentifierArgs) => Identifier;
|
|
42
54
|
toExportPath: ({ operation, baseSettings }: ToOperationExportPathArgs) => string;
|
|
43
55
|
isSelected: ({ operation, baseSettings }: IsOperationSelectedArgs) => boolean;
|
|
44
|
-
pinnable: boolean;
|
|
45
56
|
isSupported: (operation: OasOperation) => boolean;
|
|
57
|
+
pinnable: boolean;
|
|
46
58
|
} & Function;
|
|
47
59
|
export {};
|
|
48
60
|
//# sourceMappingURL=OperationInsertable.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OperationInsertable.d.ts","sourceRoot":"","sources":["../../../src/dsl/operation/OperationInsertable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AACpE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAC5D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAA;AAC3D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAA;AACvE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAElD,KAAK,kCAAkC,GAAG;IACxC,OAAO,EAAE,eAAe,CAAA;IACxB,QAAQ,EAAE,eAAe,CAAA;IACzB,SAAS,EAAE,YAAY,CAAA;CACxB,CAAA;AAED,MAAM,MAAM,yBAAyB,GAAG;IACtC,SAAS,EAAE,YAAY,CAAA;IACvB,YAAY,EAAE,YAAY,CAAA;CAC3B,CAAA;AAED,MAAM,MAAM,yBAAyB,GAAG;IACtC,SAAS,EAAE,YAAY,CAAA;IACvB,YAAY,EAAE,YAAY,CAAA;CAC3B,CAAA;AAED,MAAM,MAAM,uBAAuB,GAAG;IACpC,SAAS,EAAE,YAAY,CAAA;IACvB,YAAY,EAAE,YAAY,CAAA;CAC3B,CAAA;AAED,MAAM,MAAM,sBAAsB,GAAG;IACnC,kBAAkB,EAAE,CAAC,SAAS,EAAE,YAAY,KAAK,IAAI,CAAA;CACtD,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG;IAC7B,KAAK,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"OperationInsertable.d.ts","sourceRoot":"","sources":["../../../src/dsl/operation/OperationInsertable.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AACpE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAC5D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAA;AAC3D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAA;AACvE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAElD,KAAK,kCAAkC,GAAG;IACxC,OAAO,EAAE,eAAe,CAAA;IACxB,QAAQ,EAAE,eAAe,CAAA;IACzB,SAAS,EAAE,YAAY,CAAA;CACxB,CAAA;AAED,MAAM,MAAM,yBAAyB,GAAG;IACtC,SAAS,EAAE,YAAY,CAAA;IACvB,YAAY,EAAE,YAAY,CAAA;CAC3B,CAAA;AAED,MAAM,MAAM,yBAAyB,GAAG;IACtC,SAAS,EAAE,YAAY,CAAA;IACvB,YAAY,EAAE,YAAY,CAAA;CAC3B,CAAA;AAED,MAAM,MAAM,uBAAuB,GAAG;IACpC,SAAS,EAAE,YAAY,CAAA;IACvB,YAAY,EAAE,YAAY,CAAA;CAC3B,CAAA;AAED,MAAM,MAAM,uBAAuB,GAAG;IACpC,SAAS,EAAE,YAAY,CAAA;IACvB,YAAY,EAAE,YAAY,CAA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,KAAK,MAAM,CAAA;IAEhF,UAAU,EAAE,CAAC,EAAE,SAAS,EAAE,YAAY,EAAE,EAAE,uBAAuB,KAAK,OAAO,CAAA;IAC7E,WAAW,EAAE,CAAC,SAAS,EAAE,YAAY,KAAK,OAAO,CAAA;IAEjD,QAAQ,EAAE,OAAO,CAAA;CAGlB,GAAG,QAAQ,CAAA"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import type { OasOperation } from '../../oas/operation/Operation.js';
|
|
2
|
+
import { type GatewayConstructorArgs } from '../GatewayBase.js';
|
|
3
|
+
import type { Identifier } from '../Identifier.js';
|
|
4
|
+
import type { BaseSettings } from '../../types/Settings.js';
|
|
5
|
+
import type { IsOperationSelectedArgs } from './OperationInsertable.js';
|
|
6
|
+
export type ToOperationGatewayArgs = {
|
|
7
|
+
id: string;
|
|
8
|
+
toIdentifier: (baseSettings: BaseSettings) => Identifier;
|
|
9
|
+
toExportPath: (baseSettings: BaseSettings) => string;
|
|
10
|
+
isGeneratorSelected?: (baseSettings: BaseSettings) => boolean;
|
|
11
|
+
isOperationSelected?: ({ operation, baseSettings }: IsOperationSelectedArgs) => boolean;
|
|
12
|
+
isSupported?: (operation: OasOperation) => boolean;
|
|
13
|
+
};
|
|
14
|
+
export declare const toOperationGateway: (config: ToOperationGatewayArgs) => {
|
|
15
|
+
new ({ context, settings }: GatewayConstructorArgs): {
|
|
16
|
+
settings: import("../ContentSettings.js").ContentSettings;
|
|
17
|
+
context: import("../../mod.js").GenerateContext;
|
|
18
|
+
skipped: boolean;
|
|
19
|
+
generatorKey: import("../../mod.js").GeneratorKey | undefined;
|
|
20
|
+
register(args: import("../../mod.js").RegisterArgs): void;
|
|
21
|
+
};
|
|
22
|
+
id: string;
|
|
23
|
+
type: "operation";
|
|
24
|
+
_class: "OperationGateway";
|
|
25
|
+
toIdentifier: (baseSettings: BaseSettings) => Identifier;
|
|
26
|
+
toExportPath: (baseSettings: BaseSettings) => string;
|
|
27
|
+
isGeneratorSelected: (baseSettings: BaseSettings) => boolean;
|
|
28
|
+
isOperationSelected: ({ operation, baseSettings }: IsOperationSelectedArgs) => boolean;
|
|
29
|
+
isSupported: (operation: OasOperation) => boolean;
|
|
30
|
+
pinnable: boolean;
|
|
31
|
+
};
|
|
32
|
+
//# sourceMappingURL=toOperationGateway.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toOperationGateway.d.ts","sourceRoot":"","sources":["../../../src/dsl/operation/toOperationGateway.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AACpE,OAAO,EAAe,KAAK,sBAAsB,EAAE,MAAM,mBAAmB,CAAA;AAC5E,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAClD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAA;AAC3D,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAA;AAEvE,MAAM,MAAM,sBAAsB,GAAG;IACnC,EAAE,EAAE,MAAM,CAAA;IAEV,YAAY,EAAE,CAAC,YAAY,EAAE,YAAY,KAAK,UAAU,CAAA;IACxD,YAAY,EAAE,CAAC,YAAY,EAAE,YAAY,KAAK,MAAM,CAAA;IAEpD,mBAAmB,CAAC,EAAE,CAAC,YAAY,EAAE,YAAY,KAAK,OAAO,CAAA;IAC7D,mBAAmB,CAAC,EAAE,CAAC,EAAE,SAAS,EAAE,YAAY,EAAE,EAAE,uBAAuB,KAAK,OAAO,CAAA;IAEvF,WAAW,CAAC,EAAE,CAAC,SAAS,EAAE,YAAY,KAAK,OAAO,CAAA;CACnD,CAAA;AAED,eAAO,MAAM,kBAAkB,WAAY,sBAAsB;gCAe1B,sBAAsB;;;;;;;;;;iCAxB9B,YAAY,KAAK,UAAU;iCAC3B,YAAY,KAAK,MAAM;wCAEf,YAAY,KAAK,OAAO;uDACT,uBAAuB,KAAK,OAAO;6BAE7D,YAAY,KAAK,OAAO;;CAwBnD,CAAA"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __setFunctionName = (this && this.__setFunctionName) || function (f, name, prefix) {
|
|
3
|
+
if (typeof name === "symbol") name = name.description ? "[".concat(name.description, "]") : "";
|
|
4
|
+
return Object.defineProperty(f, "name", { configurable: true, value: prefix ? "".concat(prefix, " ", name) : name });
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.toOperationGateway = void 0;
|
|
8
|
+
const GatewayBase_js_1 = require("../GatewayBase.js");
|
|
9
|
+
const toOperationGateway = (config) => {
|
|
10
|
+
var _a;
|
|
11
|
+
const OperationGateway = (_a = class extends GatewayBase_js_1.GatewayBase {
|
|
12
|
+
constructor({ context, settings }) {
|
|
13
|
+
super({ context, settings });
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
__setFunctionName(_a, "OperationGateway"),
|
|
17
|
+
Object.defineProperty(_a, "id", {
|
|
18
|
+
enumerable: true,
|
|
19
|
+
configurable: true,
|
|
20
|
+
writable: true,
|
|
21
|
+
value: config.id
|
|
22
|
+
}),
|
|
23
|
+
Object.defineProperty(_a, "type", {
|
|
24
|
+
enumerable: true,
|
|
25
|
+
configurable: true,
|
|
26
|
+
writable: true,
|
|
27
|
+
value: 'operation'
|
|
28
|
+
}),
|
|
29
|
+
Object.defineProperty(_a, "_class", {
|
|
30
|
+
enumerable: true,
|
|
31
|
+
configurable: true,
|
|
32
|
+
writable: true,
|
|
33
|
+
value: 'OperationGateway'
|
|
34
|
+
}),
|
|
35
|
+
Object.defineProperty(_a, "toIdentifier", {
|
|
36
|
+
enumerable: true,
|
|
37
|
+
configurable: true,
|
|
38
|
+
writable: true,
|
|
39
|
+
value: config.toIdentifier.bind(config)
|
|
40
|
+
}),
|
|
41
|
+
Object.defineProperty(_a, "toExportPath", {
|
|
42
|
+
enumerable: true,
|
|
43
|
+
configurable: true,
|
|
44
|
+
writable: true,
|
|
45
|
+
value: config.toExportPath.bind(config)
|
|
46
|
+
}),
|
|
47
|
+
Object.defineProperty(_a, "isGeneratorSelected", {
|
|
48
|
+
enumerable: true,
|
|
49
|
+
configurable: true,
|
|
50
|
+
writable: true,
|
|
51
|
+
value: config.isGeneratorSelected ?? (() => true)
|
|
52
|
+
}),
|
|
53
|
+
Object.defineProperty(_a, "isOperationSelected", {
|
|
54
|
+
enumerable: true,
|
|
55
|
+
configurable: true,
|
|
56
|
+
writable: true,
|
|
57
|
+
value: config.isOperationSelected ?? (() => true)
|
|
58
|
+
}),
|
|
59
|
+
Object.defineProperty(_a, "isSupported", {
|
|
60
|
+
enumerable: true,
|
|
61
|
+
configurable: true,
|
|
62
|
+
writable: true,
|
|
63
|
+
value: config.isSupported ?? (() => true)
|
|
64
|
+
}),
|
|
65
|
+
Object.defineProperty(_a, "pinnable", {
|
|
66
|
+
enumerable: true,
|
|
67
|
+
configurable: true,
|
|
68
|
+
writable: true,
|
|
69
|
+
value: false
|
|
70
|
+
}),
|
|
71
|
+
_a);
|
|
72
|
+
return OperationGateway;
|
|
73
|
+
};
|
|
74
|
+
exports.toOperationGateway = toOperationGateway;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import type { GenerateContext } from '../../context/GenerateContext.js';
|
|
2
|
+
import type { OasOperation } from '../../oas/operation/Operation.js';
|
|
3
|
+
import type { ContentSettings } from '../ContentSettings.js';
|
|
4
|
+
import type { ToOperationIdentifierArgs, ToOperationExportPathArgs, IsOperationSelectedArgs } from './OperationInsertable.js';
|
|
5
|
+
import type { Identifier } from '../Identifier.js';
|
|
6
|
+
export type OperationInsertableArgs = {
|
|
7
|
+
context: GenerateContext;
|
|
8
|
+
settings: ContentSettings;
|
|
9
|
+
operation: OasOperation;
|
|
10
|
+
};
|
|
11
|
+
export type ToOperationInsertableArgs = {
|
|
12
|
+
id: string;
|
|
13
|
+
toIdentifier: ({ operation, baseSettings }: ToOperationIdentifierArgs) => Identifier;
|
|
14
|
+
toExportPath: ({ operation, baseSettings }: ToOperationExportPathArgs) => string;
|
|
15
|
+
isSelected?: ({ operation, baseSettings }: IsOperationSelectedArgs) => boolean;
|
|
16
|
+
isSupported?: (operation: OasOperation) => boolean;
|
|
17
|
+
pinnable?: boolean;
|
|
18
|
+
};
|
|
19
|
+
export declare const toOperationInsertable: (config: ToOperationInsertableArgs) => {
|
|
20
|
+
new (args: OperationInsertableArgs): {
|
|
21
|
+
settings: ContentSettings;
|
|
22
|
+
operation: OasOperation;
|
|
23
|
+
generatorKey: import("../../types/GeneratorKeys.js").GeneratorKey;
|
|
24
|
+
insert<V extends import("../../mod.js").GeneratedValue>(insertable: import("./OperationInsertable.js").OperationInsertable<V>, operation: OasOperation): import("../Inserted.js").Inserted<V, "force">;
|
|
25
|
+
createAndRegisterDefinition<Schema extends import("../../mod.js").SchemaType>({ schema, identifier, schemaToValueFn }: {
|
|
26
|
+
schema: Schema;
|
|
27
|
+
identifier: Identifier;
|
|
28
|
+
schemaToValueFn: import("../../mod.js").SchemaToValueFn;
|
|
29
|
+
}): import("../Definition.js").Definition<import("../../mod.js").TypeSystemOutput<Schema["type"]>>;
|
|
30
|
+
register(args: Partial<import("../../context/GenerateContext.js").RegisterArgs>): void;
|
|
31
|
+
context: GenerateContext;
|
|
32
|
+
skipped: boolean;
|
|
33
|
+
};
|
|
34
|
+
id: string;
|
|
35
|
+
type: "operation";
|
|
36
|
+
_class: "OperationInsertable";
|
|
37
|
+
toIdentifier: ({ operation, baseSettings }: ToOperationIdentifierArgs) => Identifier;
|
|
38
|
+
toExportPath: ({ operation, baseSettings }: ToOperationExportPathArgs) => string;
|
|
39
|
+
isSelected: ({ operation, baseSettings }: IsOperationSelectedArgs) => boolean;
|
|
40
|
+
isSupported: (operation: OasOperation) => boolean;
|
|
41
|
+
pinnable: boolean;
|
|
42
|
+
};
|
|
43
|
+
//# sourceMappingURL=toOperationInsertable.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toOperationInsertable.d.ts","sourceRoot":"","sources":["../../../src/dsl/operation/toOperationInsertable.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAA;AACvE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAA;AACpE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAC5D,OAAO,KAAK,EACV,yBAAyB,EACzB,yBAAyB,EACzB,uBAAuB,EACxB,MAAM,0BAA0B,CAAA;AAEjC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAElD,MAAM,MAAM,uBAAuB,GAAG;IACpC,OAAO,EAAE,eAAe,CAAA;IACxB,QAAQ,EAAE,eAAe,CAAA;IACzB,SAAS,EAAE,YAAY,CAAA;CACxB,CAAA;AAED,MAAM,MAAM,yBAAyB,GAAG;IACtC,EAAE,EAAE,MAAM,CAAA;IACV,YAAY,EAAE,CAAC,EAAE,SAAS,EAAE,YAAY,EAAE,EAAE,yBAAyB,KAAK,UAAU,CAAA;IACpF,YAAY,EAAE,CAAC,EAAE,SAAS,EAAE,YAAY,EAAE,EAAE,yBAAyB,KAAK,MAAM,CAAA;IAChF,UAAU,CAAC,EAAE,CAAC,EAAE,SAAS,EAAE,YAAY,EAAE,EAAE,uBAAuB,KAAK,OAAO,CAAA;IAC9E,WAAW,CAAC,EAAE,CAAC,SAAS,EAAE,YAAY,KAAK,OAAO,CAAA;IAClD,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB,CAAA;AAED,eAAO,MAAM,qBAAqB,WAAY,yBAAyB;eAcjD,uBAAuB;;;;;;;;;;;;;;;;;gDArBC,yBAAyB,KAAK,UAAU;gDACxC,yBAAyB,KAAK,MAAM;8CACrC,uBAAuB,KAAK,OAAO;6BACpD,YAAY,KAAK,OAAO;;CA8BnD,CAAA"}
|
|
@@ -4,12 +4,11 @@ var __setFunctionName = (this && this.__setFunctionName) || function (f, name, p
|
|
|
4
4
|
return Object.defineProperty(f, "name", { configurable: true, value: prefix ? "".concat(prefix, " ", name) : name });
|
|
5
5
|
};
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
-
exports.
|
|
7
|
+
exports.toOperationInsertable = void 0;
|
|
8
8
|
const GeneratorKeys_js_1 = require("../../types/GeneratorKeys.js");
|
|
9
9
|
const OperationBase_js_1 = require("./OperationBase.js");
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
var _a, _b;
|
|
10
|
+
const toOperationInsertable = (config) => {
|
|
11
|
+
var _a;
|
|
13
12
|
const OperationInsertable = (_a = class extends OperationBase_js_1.OperationBase {
|
|
14
13
|
constructor(args) {
|
|
15
14
|
super({
|
|
@@ -71,43 +70,6 @@ const toOperationBase = (config) => {
|
|
|
71
70
|
value: config.pinnable ?? false
|
|
72
71
|
}),
|
|
73
72
|
_a);
|
|
74
|
-
|
|
75
|
-
constructor(context) {
|
|
76
|
-
super(context);
|
|
77
|
-
}
|
|
78
|
-
},
|
|
79
|
-
__setFunctionName(_b, "OperationGateway"),
|
|
80
|
-
Object.defineProperty(_b, "id", {
|
|
81
|
-
enumerable: true,
|
|
82
|
-
configurable: true,
|
|
83
|
-
writable: true,
|
|
84
|
-
value: config.id
|
|
85
|
-
}),
|
|
86
|
-
Object.defineProperty(_b, "type", {
|
|
87
|
-
enumerable: true,
|
|
88
|
-
configurable: true,
|
|
89
|
-
writable: true,
|
|
90
|
-
value: 'operation'
|
|
91
|
-
}),
|
|
92
|
-
Object.defineProperty(_b, "_class", {
|
|
93
|
-
enumerable: true,
|
|
94
|
-
configurable: true,
|
|
95
|
-
writable: true,
|
|
96
|
-
value: 'OperationGateway'
|
|
97
|
-
}),
|
|
98
|
-
Object.defineProperty(_b, "isSupported", {
|
|
99
|
-
enumerable: true,
|
|
100
|
-
configurable: true,
|
|
101
|
-
writable: true,
|
|
102
|
-
value: config.isSupported ?? (() => true)
|
|
103
|
-
}),
|
|
104
|
-
Object.defineProperty(_b, "pinnable", {
|
|
105
|
-
enumerable: true,
|
|
106
|
-
configurable: true,
|
|
107
|
-
writable: true,
|
|
108
|
-
value: config.pinnable ?? false
|
|
109
|
-
}),
|
|
110
|
-
_b);
|
|
111
|
-
return { OperationInsertable, OperationGateway };
|
|
73
|
+
return OperationInsertable;
|
|
112
74
|
};
|
|
113
|
-
exports.
|
|
75
|
+
exports.toOperationInsertable = toOperationInsertable;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import type { ResultsItem,
|
|
1
|
+
import type { ResultsItem, ResultType } from '../types/Results.js';
|
|
2
2
|
export declare class ResultsLog {
|
|
3
3
|
#private;
|
|
4
4
|
constructor();
|
|
5
|
-
capture(stackTrail: string, result:
|
|
5
|
+
capture(stackTrail: string, result: ResultType): void;
|
|
6
6
|
toTree(): ResultsItem;
|
|
7
7
|
}
|
|
8
8
|
//# sourceMappingURL=ResultsLog.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ResultsLog.d.ts","sourceRoot":"","sources":["../../src/helpers/ResultsLog.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,
|
|
1
|
+
{"version":3,"file":"ResultsLog.d.ts","sourceRoot":"","sources":["../../src/helpers/ResultsLog.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAA;AAGlE,qBAAa,UAAU;;;IAOrB,OAAO,CAAC,UAAU,EAAE,MAAM,EAAE,MAAM,EAAE,UAAU;IAc9C,MAAM,IAAI,WAAW;CAWtB"}
|
|
@@ -36,7 +36,15 @@ class ResultsLog {
|
|
|
36
36
|
}
|
|
37
37
|
exports.ResultsLog = ResultsLog;
|
|
38
38
|
_ResultsLog_results = new WeakMap(), _ResultsLog_instances = new WeakSet(), _ResultsLog_incomingResultIsWorse = function _ResultsLog_incomingResultIsWorse(current, incoming) {
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
39
|
+
if (current === undefined) {
|
|
40
|
+
return true;
|
|
41
|
+
}
|
|
42
|
+
return resultRankings[current] < resultRankings[incoming];
|
|
43
|
+
};
|
|
44
|
+
const resultRankings = {
|
|
45
|
+
error: 50,
|
|
46
|
+
warning: 40,
|
|
47
|
+
success: 30,
|
|
48
|
+
notSelected: 20,
|
|
49
|
+
notSupported: 10
|
|
42
50
|
};
|
package/script/mod.d.ts
CHANGED
|
@@ -14,12 +14,14 @@ export * from './dsl/Inserted.js';
|
|
|
14
14
|
export * from './dsl/model/ModelBase.js';
|
|
15
15
|
export * from './dsl/model/ModelDriver.js';
|
|
16
16
|
export * from './dsl/model/ModelInsertable.js';
|
|
17
|
-
export * from './dsl/model/
|
|
17
|
+
export * from './dsl/model/toModelInsertable.js';
|
|
18
|
+
export * from './dsl/model/toModelGateway.js';
|
|
18
19
|
export * from './dsl/operation/OperationBase.js';
|
|
19
20
|
export * from './dsl/operation/OperationBase.js';
|
|
20
21
|
export * from './dsl/operation/OperationDriver.js';
|
|
21
22
|
export * from './dsl/operation/OperationInsertable.js';
|
|
22
|
-
export * from './dsl/operation/
|
|
23
|
+
export * from './dsl/operation/toOperationInsertable.js';
|
|
24
|
+
export * from './dsl/operation/toOperationGateway.js';
|
|
23
25
|
export * from './dsl/Stringable.js';
|
|
24
26
|
export * from './dsl/ValueBase.js';
|
|
25
27
|
export * from './helpers/isImported.js';
|
package/script/mod.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../src/mod.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,CAAC;AAC7B,cAAc,0BAA0B,CAAA;AACxC,cAAc,8BAA8B,CAAA;AAC5C,cAAc,2BAA2B,CAAA;AACzC,cAAc,oBAAoB,CAAA;AAClC,cAAc,0BAA0B,CAAA;AACxC,cAAc,0BAA0B,CAAA;AACxC,cAAc,qBAAqB,CAAA;AACnC,cA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AACtC,cAAc,8BAA8B,CAAA;AAC5C,cAAc,8BAA8B,CAAA;AAC5C,cAAc,kBAAkB,CAAA;AAChC,cAAc,kCAAkC,CAAA;AAChD,cAAc,wBAAwB,CAAA;AACtC,cAAc,wBAAwB,CAAA;AACtC,cAAc,kBAAkB,CAAA;AAChC,cAAc,oBAAoB,CAAA;AAClC,cAAc,0BAA0B,CAAA;AACxC,cAAc,wBAAwB,CAAA;AACtC,cAAc,2BAA2B,CAAA;AACzC,cAAc,0BAA0B,CAAA;AACxC,cAAc,mBAAmB,CAAA;AACjC,cAAc,sBAAsB,CAAA;AACpC,cAAc,2BAA2B,CAAA;AACzC,cAAc,oBAAoB,CAAA;AAClC,cAAc,qBAAqB,CAAA;AACnC,cAAc,qBAAqB,CAAA;AACnC,cAAc,uBAAuB,CAAA;AACrC,cAAc,mCAAmC,CAAA;AACjD,cAAc,6BAA6B,CAAA;AAC3C,cAAc,2BAA2B,CAAA;AACzC,cAAc,sBAAsB,CAAA;AACpC,cAAc,4BAA4B,CAAA;AAC1C,cAAc,uCAAuC,CAAA;AACrD,cAAc,gCAAgC,CAAA;AAC9C,cAAc,iCAAiC,CAAA"}
|
package/script/mod.js
CHANGED
|
@@ -30,12 +30,14 @@ __exportStar(require("./dsl/Inserted.js"), exports);
|
|
|
30
30
|
__exportStar(require("./dsl/model/ModelBase.js"), exports);
|
|
31
31
|
__exportStar(require("./dsl/model/ModelDriver.js"), exports);
|
|
32
32
|
__exportStar(require("./dsl/model/ModelInsertable.js"), exports);
|
|
33
|
-
__exportStar(require("./dsl/model/
|
|
33
|
+
__exportStar(require("./dsl/model/toModelInsertable.js"), exports);
|
|
34
|
+
__exportStar(require("./dsl/model/toModelGateway.js"), exports);
|
|
34
35
|
__exportStar(require("./dsl/operation/OperationBase.js"), exports);
|
|
35
36
|
__exportStar(require("./dsl/operation/OperationBase.js"), exports);
|
|
36
37
|
__exportStar(require("./dsl/operation/OperationDriver.js"), exports);
|
|
37
38
|
__exportStar(require("./dsl/operation/OperationInsertable.js"), exports);
|
|
38
|
-
__exportStar(require("./dsl/operation/
|
|
39
|
+
__exportStar(require("./dsl/operation/toOperationInsertable.js"), exports);
|
|
40
|
+
__exportStar(require("./dsl/operation/toOperationGateway.js"), exports);
|
|
39
41
|
__exportStar(require("./dsl/Stringable.js"), exports);
|
|
40
42
|
__exportStar(require("./dsl/ValueBase.js"), exports);
|
|
41
43
|
__exportStar(require("./helpers/isImported.js"), exports);
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import "../_dnt.polyfills.js";
|
|
2
2
|
import { z } from 'zod';
|
|
3
|
-
export type
|
|
3
|
+
export type ResultType = 'success' | 'warning' | 'error' | 'notSelected' | 'notSupported';
|
|
4
4
|
export type WarningError = 'warning' | 'error';
|
|
5
|
-
export declare const
|
|
5
|
+
export declare const resultType: z.ZodEnum<["success", "warning", "error", "notSelected", "notSupported"]>;
|
|
6
6
|
export interface ResultsItem {
|
|
7
|
-
[key: string]:
|
|
7
|
+
[key: string]: ResultType | ResultsItem | Array<ResultsItem | null>;
|
|
8
8
|
}
|
|
9
9
|
export declare const resultsItem: z.ZodType<ResultsItem>;
|
|
10
10
|
//# sourceMappingURL=Results.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Results.d.ts","sourceRoot":"","sources":["../../src/types/Results.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAC9B,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,MAAM,MAAM,
|
|
1
|
+
{"version":3,"file":"Results.d.ts","sourceRoot":"","sources":["../../src/types/Results.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAC9B,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,SAAS,GAAG,OAAO,GAAG,aAAa,GAAG,cAAc,CAAA;AAEzF,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,OAAO,CAAA;AAE9C,eAAO,MAAM,UAAU,2EAAyE,CAAA;AAEhG,MAAM,WAAW,WAAW;IAC1B,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,GAAG,WAAW,GAAG,KAAK,CAAC,WAAW,GAAG,IAAI,CAAC,CAAA;CACpE;AAED,eAAO,MAAM,WAAW,EAAE,CAAC,CAAC,OAAO,CAAC,WAAW,CAE9C,CAAA"}
|
package/script/types/Results.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.resultsItem = exports.
|
|
3
|
+
exports.resultsItem = exports.resultType = void 0;
|
|
4
4
|
require("../_dnt.polyfills.js");
|
|
5
5
|
const zod_1 = require("zod");
|
|
6
|
-
exports.
|
|
7
|
-
exports.resultsItem = zod_1.z.record(zod_1.z.lazy(() => zod_1.z.union([exports.resultsItem, exports.
|
|
6
|
+
exports.resultType = zod_1.z.enum(['success', 'warning', 'error', 'notSelected', 'notSupported']);
|
|
7
|
+
exports.resultsItem = zod_1.z.record(zod_1.z.lazy(() => zod_1.z.union([exports.resultsItem, exports.resultType, zod_1.z.array(exports.resultsItem.nullable())])));
|