@adaas/a-concept 0.1.22 → 0.1.23
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.
|
@@ -44,10 +44,26 @@ export declare class A_Stage {
|
|
|
44
44
|
* Returns the name of the stage
|
|
45
45
|
*/
|
|
46
46
|
get name(): string;
|
|
47
|
+
/**
|
|
48
|
+
* Returns the definition of the stage
|
|
49
|
+
*/
|
|
50
|
+
get definition(): A_TYPES__A_StageStep;
|
|
47
51
|
/**
|
|
48
52
|
* Returns the current status of the stage
|
|
49
53
|
*/
|
|
50
54
|
get status(): A_TYPES__A_Stage_Status;
|
|
55
|
+
/**
|
|
56
|
+
* Returns the feature that owns this stage
|
|
57
|
+
*/
|
|
58
|
+
get feature(): A_Feature;
|
|
59
|
+
/**
|
|
60
|
+
* Returns true if the stage is processed (completed, failed, or skipped)
|
|
61
|
+
*/
|
|
62
|
+
get isProcessed(): boolean;
|
|
63
|
+
/**
|
|
64
|
+
* Returns the error of the stage
|
|
65
|
+
*/
|
|
66
|
+
get error(): A_Error | undefined;
|
|
51
67
|
/**
|
|
52
68
|
* Resolves the arguments of the step
|
|
53
69
|
*
|
|
@@ -44,12 +44,38 @@ class A_Stage {
|
|
|
44
44
|
get name() {
|
|
45
45
|
return this.toString();
|
|
46
46
|
}
|
|
47
|
+
/**
|
|
48
|
+
* Returns the definition of the stage
|
|
49
|
+
*/
|
|
50
|
+
get definition() {
|
|
51
|
+
return this._definition;
|
|
52
|
+
}
|
|
47
53
|
/**
|
|
48
54
|
* Returns the current status of the stage
|
|
49
55
|
*/
|
|
50
56
|
get status() {
|
|
51
57
|
return this._status;
|
|
52
58
|
}
|
|
59
|
+
/**
|
|
60
|
+
* Returns the feature that owns this stage
|
|
61
|
+
*/
|
|
62
|
+
get feature() {
|
|
63
|
+
return this._feature;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Returns true if the stage is processed (completed, failed, or skipped)
|
|
67
|
+
*/
|
|
68
|
+
get isProcessed() {
|
|
69
|
+
return this._status === A_Stage_types_1.A_TYPES__A_Stage_Status.COMPLETED
|
|
70
|
+
|| this._status === A_Stage_types_1.A_TYPES__A_Stage_Status.FAILED
|
|
71
|
+
|| this._status === A_Stage_types_1.A_TYPES__A_Stage_Status.SKIPPED;
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Returns the error of the stage
|
|
75
|
+
*/
|
|
76
|
+
get error() {
|
|
77
|
+
return this._error;
|
|
78
|
+
}
|
|
53
79
|
/**
|
|
54
80
|
* Resolves the arguments of the step
|
|
55
81
|
*
|
|
@@ -148,7 +174,7 @@ class A_Stage {
|
|
|
148
174
|
return __awaiter(this, void 0, void 0, function* () {
|
|
149
175
|
const targetScope = A_TypeGuards_helper_1.A_TypeGuards.isScopeInstance(scope)
|
|
150
176
|
? scope
|
|
151
|
-
:
|
|
177
|
+
: this._feature.scope;
|
|
152
178
|
if (!this._processed)
|
|
153
179
|
this._processed = new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () {
|
|
154
180
|
try {
|
|
@@ -185,7 +211,7 @@ class A_Stage {
|
|
|
185
211
|
this._status = A_Stage_types_1.A_TYPES__A_Stage_Status.COMPLETED;
|
|
186
212
|
}
|
|
187
213
|
failed(error) {
|
|
188
|
-
this._error = error;
|
|
214
|
+
this._error = new A_Error_class_1.A_Error(error);
|
|
189
215
|
this._status = A_Stage_types_1.A_TYPES__A_Stage_Status.FAILED;
|
|
190
216
|
}
|
|
191
217
|
// ==========================================
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"A-Stage.class.js","sourceRoot":"","sources":["../../../../src/global/A-Stage/A-Stage.class.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,mDAIyB;AACzB,kEAAyD;AAGzD,mDAA+C;AAC/C,4DAAmD;AACnD,sFAA4E;AAO5E,MAAa,OAAO;IAyBhB;;;;;OAKG;IACH;IACI;;OAEG;IACH,OAAkB;IAClB;;OAEG;IACH,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,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC;wBAG1B,IAAI,IAAI,CAAC,WAAW,CAAC,YAAY,EAAE,CAAC;4BAChC,OAAO,OAAO,EAAE,CAAC;wBACrB,CAAC;6BAAM,CAAC;4BACJ,OAAO,MAAM,CAAC,YAAY,CAAC,CAAC;wBAChC,CAAC;oBACL,CAAC;gBACL,CAAC,CAAA,CAAC,CAAC;YAEX,OAAO,IAAI,CAAC,UAAU,CAAC;QAC3B,CAAC;KAAA;IAGD,6CAA6C;IAC7C,4CAA4C;IAC5C,6CAA6C;IAEnC,SAAS;QACf,IAAI,CAAC,OAAO,GAAG,uCAAuB,CAAC,SAAS,CAAC;IACrD,CAAC;IAES,MAAM,CACZ,KAA4B;QAE5B,IAAI,CAAC,MAAM,GAAG,IAAI,uBAAO,CAAC,KAAK,CAAC,CAAC;QAEjC,IAAI,CAAC,OAAO,GAAG,uCAAuB,CAAC,MAAM,CAAC;IAClD,CAAC;IAID,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C;;;OAGG;IACH,MAAM;QACF,OAAO;YACH,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,MAAM,EAAE,IAAI,CAAC,MAAM;SACtB,CAAA;IACL,CAAC;IAED;;;;OAIG;IACH,QAAQ;QACJ,OAAO,WAAW,IAAI,CAAC,QAAQ,CAAC,IAAI,KAAK,IAAI,CAAC,WAAW,CAAC,QAAQ,IAAI,IAAI,CAAC,WAAW,CAAC,OAAO,GAAG,CAAC;IACtG,CAAC;CACJ;AApSD,0BAoSC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adaas/a-concept",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.23",
|
|
4
4
|
"description": "A-Concept is a framework to build new Applications within or outside the ADAAS ecosystem. This framework is designed to be modular structure regardless environment and program goal.",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.mjs",
|
|
@@ -50,13 +50,11 @@
|
|
|
50
50
|
"url": "https://github.com/ADAAS-org/adaas-adf-auth/issues"
|
|
51
51
|
},
|
|
52
52
|
"homepage": "https://github.com/ADAAS-org/adaas-adf-auth#readme",
|
|
53
|
-
"dependencies": {
|
|
54
|
-
"@types/node": "^20.10.0"
|
|
55
|
-
},
|
|
56
53
|
"devDependencies": {
|
|
57
54
|
"@types/chai": "^4.3.14",
|
|
58
55
|
"@types/jest": "^29.5.12",
|
|
59
56
|
"@types/mocha": "^10.0.6",
|
|
57
|
+
"@types/node": "^24.9.1",
|
|
60
58
|
"chai": "^5.1.0",
|
|
61
59
|
"dotenv": "^16.4.5",
|
|
62
60
|
"jest": "^29.7.0",
|
|
@@ -28,7 +28,7 @@ export class A_Stage {
|
|
|
28
28
|
/**
|
|
29
29
|
* Possible errors during stage processing
|
|
30
30
|
*/
|
|
31
|
-
private _error?:
|
|
31
|
+
private _error?: A_Error;
|
|
32
32
|
/**
|
|
33
33
|
* Indicates the current status of the stage
|
|
34
34
|
*/
|
|
@@ -66,13 +66,38 @@ export class A_Stage {
|
|
|
66
66
|
get name(): string {
|
|
67
67
|
return this.toString();
|
|
68
68
|
}
|
|
69
|
+
/**
|
|
70
|
+
* Returns the definition of the stage
|
|
71
|
+
*/
|
|
72
|
+
get definition(): A_TYPES__A_StageStep {
|
|
73
|
+
return this._definition;
|
|
74
|
+
}
|
|
69
75
|
/**
|
|
70
76
|
* Returns the current status of the stage
|
|
71
77
|
*/
|
|
72
78
|
get status(): A_TYPES__A_Stage_Status {
|
|
73
79
|
return this._status;
|
|
74
80
|
}
|
|
75
|
-
|
|
81
|
+
/**
|
|
82
|
+
* Returns the feature that owns this stage
|
|
83
|
+
*/
|
|
84
|
+
get feature(): A_Feature {
|
|
85
|
+
return this._feature;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Returns true if the stage is processed (completed, failed, or skipped)
|
|
89
|
+
*/
|
|
90
|
+
get isProcessed(): boolean {
|
|
91
|
+
return this._status === A_TYPES__A_Stage_Status.COMPLETED
|
|
92
|
+
|| this._status === A_TYPES__A_Stage_Status.FAILED
|
|
93
|
+
|| this._status === A_TYPES__A_Stage_Status.SKIPPED;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* Returns the error of the stage
|
|
97
|
+
*/
|
|
98
|
+
get error(): A_Error | undefined {
|
|
99
|
+
return this._error;
|
|
100
|
+
}
|
|
76
101
|
|
|
77
102
|
/**
|
|
78
103
|
* Resolves the arguments of the step
|
|
@@ -205,7 +230,7 @@ export class A_Stage {
|
|
|
205
230
|
|
|
206
231
|
const targetScope = A_TypeGuards.isScopeInstance(scope)
|
|
207
232
|
? scope
|
|
208
|
-
:
|
|
233
|
+
: this._feature.scope;
|
|
209
234
|
|
|
210
235
|
if (!this._processed)
|
|
211
236
|
this._processed = new Promise<void>(
|
|
@@ -253,7 +278,7 @@ export class A_Stage {
|
|
|
253
278
|
protected failed(
|
|
254
279
|
error: Error | A_Error | any
|
|
255
280
|
) {
|
|
256
|
-
this._error = error;
|
|
281
|
+
this._error = new A_Error(error);
|
|
257
282
|
|
|
258
283
|
this._status = A_TYPES__A_Stage_Status.FAILED;
|
|
259
284
|
}
|