@hahnpro/flow-sdk 8.0.2 → 8.0.4
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/ContextManager.d.ts
CHANGED
|
@@ -8,14 +8,15 @@ export declare class ContextManager {
|
|
|
8
8
|
/**
|
|
9
9
|
* Constructor of the ContextManager.
|
|
10
10
|
* @param {Logger} logger - The logger instance for logging messages.
|
|
11
|
-
* @param {Record<string, any>} [
|
|
11
|
+
* @param {Record<string, any>} [flowProperties={}] - Initial properties to set.
|
|
12
12
|
*/
|
|
13
|
-
constructor(logger: Logger,
|
|
13
|
+
constructor(logger: Logger, flowProperties?: Record<string, any>);
|
|
14
14
|
/**
|
|
15
15
|
* Init or overwrite all properties.
|
|
16
16
|
* @param properties
|
|
17
17
|
*/
|
|
18
18
|
overwriteAllProperties(properties?: Record<string, any>): void;
|
|
19
|
+
updateFlowProperties(properties?: Record<string, any>): void;
|
|
19
20
|
/**
|
|
20
21
|
* Get a copy of the current properties.
|
|
21
22
|
* @returns {Record<string, any>} A copy of the properties.
|
package/dist/ContextManager.js
CHANGED
|
@@ -6,12 +6,15 @@ const tslib_1 = require("tslib");
|
|
|
6
6
|
const lodash_1 = require("lodash");
|
|
7
7
|
const string_interp_1 = tslib_1.__importDefault(require("string-interp"));
|
|
8
8
|
class ContextManager {
|
|
9
|
-
constructor(logger,
|
|
9
|
+
constructor(logger, flowProperties = {}) {
|
|
10
10
|
this.logger = logger;
|
|
11
|
-
this.properties =
|
|
11
|
+
this.properties = { flow: flowProperties };
|
|
12
12
|
}
|
|
13
13
|
overwriteAllProperties(properties = {}) {
|
|
14
|
-
this.properties = properties;
|
|
14
|
+
this.properties = { flow: properties };
|
|
15
|
+
}
|
|
16
|
+
updateFlowProperties(properties = {}) {
|
|
17
|
+
this.properties.flow = properties;
|
|
15
18
|
}
|
|
16
19
|
getProperties() {
|
|
17
20
|
return { ...this.properties };
|
package/dist/FlowApplication.js
CHANGED
|
@@ -127,7 +127,7 @@ class FlowApplication {
|
|
|
127
127
|
context = this.context;
|
|
128
128
|
}
|
|
129
129
|
if (flow.properties) {
|
|
130
|
-
this.contextManager.
|
|
130
|
+
this.contextManager.updateFlowProperties(flow.properties);
|
|
131
131
|
for (const element of Object.values(this.elements)) {
|
|
132
132
|
element.replacePlaceholderAndSetProperties();
|
|
133
133
|
element.onFlowPropertiesChanged?.(flow.properties);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hahnpro/flow-sdk",
|
|
3
|
-
"version": "8.0.
|
|
3
|
+
"version": "8.0.4",
|
|
4
4
|
"description": "SDK for building Flow Modules",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": {
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"amqp-connection-manager": "4.1.14",
|
|
28
|
-
"amqplib": "0.10.
|
|
28
|
+
"amqplib": "0.10.5",
|
|
29
29
|
"class-transformer": "0.5.1",
|
|
30
30
|
"class-validator": "~0.14.1",
|
|
31
31
|
"cloudevents": "8.0.2",
|
|
@@ -36,19 +36,19 @@
|
|
|
36
36
|
"reflect-metadata": "0.2.2",
|
|
37
37
|
"rxjs": "7.8.1",
|
|
38
38
|
"string-interp": "0.3.6",
|
|
39
|
-
"@hahnpro/hpc-api": "5.3.
|
|
39
|
+
"@hahnpro/hpc-api": "5.3.2"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@types/amqplib": "0.10.
|
|
42
|
+
"@types/amqplib": "0.10.6",
|
|
43
43
|
"@types/jest": "29.5.14",
|
|
44
44
|
"@types/lodash": "4.17.13",
|
|
45
|
-
"@types/node": "
|
|
45
|
+
"@types/node": "22.10.1",
|
|
46
46
|
"class-validator-jsonschema": "5.0.1",
|
|
47
47
|
"jest": "29.7.0",
|
|
48
|
-
"typescript": "5.
|
|
48
|
+
"typescript": "5.7.2"
|
|
49
49
|
},
|
|
50
50
|
"peerDependencies": {
|
|
51
|
-
"axios": "1.7.
|
|
51
|
+
"axios": "1.7.9",
|
|
52
52
|
"class-transformer": "0.5.1",
|
|
53
53
|
"class-validator": "0.14.1",
|
|
54
54
|
"lodash": "4.17.21",
|