@woosh/meep-engine 2.98.1 → 2.98.3
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/build/meep.cjs +44 -62
- package/build/meep.min.js +1 -1
- package/build/meep.module.js +44 -62
- package/package.json +1 -1
- package/src/core/events/signal/Signal.d.ts.map +1 -1
- package/src/core/events/signal/Signal.js +21 -53
- package/src/core/events/signal/SignalBinding.d.ts +8 -0
- package/src/core/events/signal/SignalBinding.d.ts.map +1 -1
- package/src/core/events/signal/SignalBinding.js +17 -0
- package/src/core/events/signal/SignalFlags.d.ts +0 -1
- package/src/core/events/signal/SignalFlags.js +1 -6
- package/src/core/model/node-graph/node/NodeDescription.d.ts.map +1 -1
- package/src/core/model/node-graph/node/NodeDescription.js +2 -0
package/build/meep.module.js
CHANGED
|
@@ -888,6 +888,13 @@ function m4_multiply(out, a, b) {
|
|
|
888
888
|
out[15] = b0 * a03 + b1 * a13 + b2 * a23 + b3 * a33;
|
|
889
889
|
}
|
|
890
890
|
|
|
891
|
+
const SignalFlags = {
|
|
892
|
+
/**
|
|
893
|
+
* If set - signal will not invoke handlers when dispatched
|
|
894
|
+
*/
|
|
895
|
+
Silent: 1
|
|
896
|
+
};
|
|
897
|
+
|
|
891
898
|
/**
|
|
892
899
|
*
|
|
893
900
|
* @enum {number}
|
|
@@ -966,18 +973,6 @@ class SignalHandler {
|
|
|
966
973
|
*/
|
|
967
974
|
SignalHandler.prototype.isSignalHandler = true;
|
|
968
975
|
|
|
969
|
-
const SignalFlags = {
|
|
970
|
-
/**
|
|
971
|
-
* If set - signal will not invoke handlers when dispatched
|
|
972
|
-
*/
|
|
973
|
-
Silent: 1,
|
|
974
|
-
/**
|
|
975
|
-
* Is set at the start of the dispatch and cleared at the end
|
|
976
|
-
* @deprecated
|
|
977
|
-
*/
|
|
978
|
-
Dispatching: 2
|
|
979
|
-
};
|
|
980
|
-
|
|
981
976
|
/**
|
|
982
977
|
*
|
|
983
978
|
* @author Alex Goldring
|
|
@@ -987,6 +982,7 @@ const SignalFlags = {
|
|
|
987
982
|
|
|
988
983
|
/**
|
|
989
984
|
* Common dispatch stack
|
|
985
|
+
* @readonly
|
|
990
986
|
* @type {SignalHandler[]}
|
|
991
987
|
*/
|
|
992
988
|
const dispatch_stack = [];
|
|
@@ -999,40 +995,17 @@ let dispatch_stack_top = 0;
|
|
|
999
995
|
*/
|
|
1000
996
|
class Signal {
|
|
1001
997
|
/**
|
|
1002
|
-
*
|
|
1003
|
-
* @
|
|
1004
|
-
*/
|
|
1005
|
-
constructor() {
|
|
1006
|
-
/**
|
|
1007
|
-
* @private
|
|
1008
|
-
* @type {SignalHandler[]}
|
|
1009
|
-
*/
|
|
1010
|
-
this.handlers = [];
|
|
1011
|
-
|
|
1012
|
-
/**
|
|
1013
|
-
* Internal flag bitmask
|
|
1014
|
-
* @private
|
|
1015
|
-
* @type {number}
|
|
1016
|
-
*/
|
|
1017
|
-
this.flags = 0;
|
|
1018
|
-
}
|
|
1019
|
-
|
|
1020
|
-
/**
|
|
1021
|
-
* @deprecated
|
|
1022
|
-
* @returns {boolean}
|
|
998
|
+
* @private
|
|
999
|
+
* @type {SignalHandler[]}
|
|
1023
1000
|
*/
|
|
1024
|
-
|
|
1025
|
-
return this.getFlag(SignalFlags.Dispatching);
|
|
1026
|
-
}
|
|
1001
|
+
handlers = [];
|
|
1027
1002
|
|
|
1028
1003
|
/**
|
|
1029
|
-
*
|
|
1030
|
-
* @
|
|
1004
|
+
* Internal flag bitmask
|
|
1005
|
+
* @private
|
|
1006
|
+
* @type {number}
|
|
1031
1007
|
*/
|
|
1032
|
-
|
|
1033
|
-
this.writeFlag(SignalFlags.Dispatching, v);
|
|
1034
|
-
}
|
|
1035
|
-
|
|
1008
|
+
flags = 0;
|
|
1036
1009
|
|
|
1037
1010
|
/**
|
|
1038
1011
|
*
|
|
@@ -1094,14 +1067,15 @@ class Signal {
|
|
|
1094
1067
|
|
|
1095
1068
|
|
|
1096
1069
|
/**
|
|
1097
|
-
*
|
|
1098
|
-
* @param {function}
|
|
1070
|
+
* Checks if a given signal handler is present or not
|
|
1071
|
+
* @param {function} handler
|
|
1072
|
+
* @param {*} [thisArg] if not present, will not be considered
|
|
1099
1073
|
* @returns {boolean}
|
|
1100
1074
|
*/
|
|
1101
|
-
contains(
|
|
1075
|
+
contains(handler, thisArg) {
|
|
1102
1076
|
const handlers = this.handlers;
|
|
1103
1077
|
|
|
1104
|
-
const i = findSignalHandlerIndexByHandle(handlers,
|
|
1078
|
+
const i = findSignalHandlerIndexByHandle(handlers, handler, thisArg);
|
|
1105
1079
|
|
|
1106
1080
|
return i !== -1;
|
|
1107
1081
|
}
|
|
@@ -1123,7 +1097,7 @@ class Signal {
|
|
|
1123
1097
|
}
|
|
1124
1098
|
|
|
1125
1099
|
/**
|
|
1126
|
-
*
|
|
1100
|
+
* Handler will only be run once, it will be removed automatically after the first execution
|
|
1127
1101
|
* @param {function} h
|
|
1128
1102
|
* @param {*} [context]
|
|
1129
1103
|
*/
|
|
@@ -1170,7 +1144,10 @@ class Signal {
|
|
|
1170
1144
|
}
|
|
1171
1145
|
|
|
1172
1146
|
/**
|
|
1173
|
-
* Remove all handlers
|
|
1147
|
+
* Remove all handlers.
|
|
1148
|
+
* Please note that this will remove even all handlers, irrespective of where they were added from. If another script is attaching to the same signal, using this method will potentially break that code.
|
|
1149
|
+
* For most use cases, prefer to use {@link remove} method instead, or make use of {@link SignalBinding} if you need to keep track of multiple handlers
|
|
1150
|
+
* NOTE: Consider this method to be unsafe, only use it when you understand the implications
|
|
1174
1151
|
*/
|
|
1175
1152
|
removeAll() {
|
|
1176
1153
|
const handlers = this.handlers;
|
|
@@ -1178,6 +1155,7 @@ class Signal {
|
|
|
1178
1155
|
}
|
|
1179
1156
|
|
|
1180
1157
|
/**
|
|
1158
|
+
* NOTE: because of polymorphic call-site nature of this method, it's always better for performance to use monomorphic methods like `send0`, `send1` etc.
|
|
1181
1159
|
* @param {...*} args
|
|
1182
1160
|
*/
|
|
1183
1161
|
dispatch(...args) {
|
|
@@ -1186,13 +1164,8 @@ class Signal {
|
|
|
1186
1164
|
return;
|
|
1187
1165
|
}
|
|
1188
1166
|
|
|
1189
|
-
//mark dispatch process
|
|
1190
|
-
this.setFlag(SignalFlags.Dispatching);
|
|
1191
|
-
|
|
1192
1167
|
dispatchViaProxy(this.handlers, args);
|
|
1193
1168
|
|
|
1194
|
-
//mark end of dispatch process
|
|
1195
|
-
this.clearFlag(SignalFlags.Dispatching);
|
|
1196
1169
|
}
|
|
1197
1170
|
|
|
1198
1171
|
/**
|
|
@@ -1558,14 +1531,6 @@ class Signal {
|
|
|
1558
1531
|
dispatch_stack_top = stack_pointer;
|
|
1559
1532
|
}
|
|
1560
1533
|
|
|
1561
|
-
/**
|
|
1562
|
-
* @deprecated do not use
|
|
1563
|
-
* @returns {boolean}
|
|
1564
|
-
*/
|
|
1565
|
-
isDispatching() {
|
|
1566
|
-
return this.getFlag(SignalFlags.Dispatching);
|
|
1567
|
-
}
|
|
1568
|
-
|
|
1569
1534
|
/**
|
|
1570
1535
|
*
|
|
1571
1536
|
* @param {Signal} other
|
|
@@ -1596,7 +1561,7 @@ Signal.prototype.isSignal = true;
|
|
|
1596
1561
|
*
|
|
1597
1562
|
* @param {SignalHandler[]} handlers
|
|
1598
1563
|
* @param {function} f
|
|
1599
|
-
* @param thisArg
|
|
1564
|
+
* @param {*} [thisArg]
|
|
1600
1565
|
* @returns {number} index of the handler, or -1 if not found
|
|
1601
1566
|
*/
|
|
1602
1567
|
function findSignalHandlerIndexByHandle(handlers, f, thisArg) {
|
|
@@ -68274,6 +68239,23 @@ class SignalBinding {
|
|
|
68274
68239
|
this.#linked = false;
|
|
68275
68240
|
this.signal.remove(this.handler, this.context);
|
|
68276
68241
|
}
|
|
68242
|
+
|
|
68243
|
+
/**
|
|
68244
|
+
* Creates a {@link SignalBinding} and links it immediately. Utility method
|
|
68245
|
+
* @param {Signal} signal
|
|
68246
|
+
* @param {function} handler
|
|
68247
|
+
* @param {*} [context]
|
|
68248
|
+
* @return {SignalBinding}
|
|
68249
|
+
*/
|
|
68250
|
+
static bind(
|
|
68251
|
+
signal, handler, context
|
|
68252
|
+
) {
|
|
68253
|
+
const r = new SignalBinding(signal, handler, context);
|
|
68254
|
+
|
|
68255
|
+
r.link();
|
|
68256
|
+
|
|
68257
|
+
return r;
|
|
68258
|
+
}
|
|
68277
68259
|
}
|
|
68278
68260
|
|
|
68279
68261
|
/**
|
package/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Signal.d.ts","sourceRoot":"","sources":["../../../../../src/core/events/signal/Signal.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Signal.d.ts","sourceRoot":"","sources":["../../../../../src/core/events/signal/Signal.js"],"names":[],"mappings":"AAslBA;;;;;;GAMG;AACH,yDALW,aAAa,EAAE,+BAGb,MAAM,CAoBlB;AAED;;;;;;GAMG;AACH,mEALW,aAAa,EAAE,0BAGb,MAAM,CAclB;AAiDD;;;;GAIG;AACH,2CAHW,aAAa,EAAE,sBA8BzB;AAlsBD;;;;GAIG;AACH;IACI;;;OAGG;IACH,iBAAc;IAEd;;;;OAIG;IACH,cAAU;IAWV;;;OAGG;IACH,yBAEC;IAfD;;;OAGG;IACH,sBAEC;IAYD;;;;OAIG;IACH,cAHW,MAAM;;KAAY,GAChB,IAAI,CAIhB;IAED;;;;OAIG;IACH,gBAHW,MAAM;;KAAY,GAChB,IAAI,CAIhB;IAED;;;;OAIG;IACH,gBAHW,MAAM;;KAAY,SAClB,OAAO,QAQjB;IAED;;;;OAIG;IACH,cAHW,MAAM;;KAAY,GAChB,OAAO,CAInB;IAGD;;;;;OAKG;IACH,4CAFa,OAAO,CAQnB;IAED,aAEC;IAED,eAEC;IAED;;;OAGG;IACH,eAFa,OAAO,CAInB;IAED;;;;OAIG;IACH,yCAQC;IAED;;;;OAIG;IACH,sCAYC;IAED;;;;;OAKG;IACH,oCAFa,OAAO,CAUnB;IAED;;;;;OAKG;IACH,kBAGC;IAED;;;OAGG;IACH,+BAQC;IAED;;;OAGG;IACH,cA4CC;IAED;;;;OAIG;IACH,sBA6CC;IAED;;;;OAIG;IACH,4BA4CC;IAED;;;;;OAKG;IACH,oCA4CC;IAED;;;;;;OAMG;IACH,4CA4CC;IAED;;;;;;;;OAQG;IACH,4DA4CC;IAED;;;;;;;;;;OAUG;IACH,4EA4CC;IAED;;;;OAIG;IACH,aAHW,MAAM,GACJ,MAAM,CAalB;IAIL;;;OAGG;IACH,mBAFU,OAAO,CAEQ;CAPxB;;8BApkBiD,oBAAoB"}
|
|
@@ -6,11 +6,12 @@
|
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
import { assert } from "../../assert.js";
|
|
9
|
-
import { SignalHandler, SignalHandlerFlags } from "./SignalHandler.js";
|
|
10
9
|
import { SignalFlags } from "./SignalFlags.js";
|
|
10
|
+
import { SignalHandler, SignalHandlerFlags } from "./SignalHandler.js";
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
13
|
* Common dispatch stack
|
|
14
|
+
* @readonly
|
|
14
15
|
* @type {SignalHandler[]}
|
|
15
16
|
*/
|
|
16
17
|
const dispatch_stack = [];
|
|
@@ -23,42 +24,17 @@ let dispatch_stack_top = 0;
|
|
|
23
24
|
*/
|
|
24
25
|
export class Signal {
|
|
25
26
|
/**
|
|
26
|
-
*
|
|
27
|
-
* @
|
|
27
|
+
* @private
|
|
28
|
+
* @type {SignalHandler[]}
|
|
28
29
|
*/
|
|
29
|
-
|
|
30
|
-
/**
|
|
31
|
-
* @private
|
|
32
|
-
* @type {SignalHandler[]}
|
|
33
|
-
*/
|
|
34
|
-
this.handlers = [];
|
|
35
|
-
|
|
36
|
-
/**
|
|
37
|
-
* Internal flag bitmask
|
|
38
|
-
* @private
|
|
39
|
-
* @type {number}
|
|
40
|
-
*/
|
|
41
|
-
this.flags = 0;
|
|
42
|
-
}
|
|
30
|
+
handlers = [];
|
|
43
31
|
|
|
44
32
|
/**
|
|
45
|
-
*
|
|
46
|
-
* @
|
|
33
|
+
* Internal flag bitmask
|
|
34
|
+
* @private
|
|
35
|
+
* @type {number}
|
|
47
36
|
*/
|
|
48
|
-
|
|
49
|
-
console.warn('deprecated, use .isDispatching instead');
|
|
50
|
-
return this.getFlag(SignalFlags.Dispatching);
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
/**
|
|
54
|
-
* @deprecated
|
|
55
|
-
* @param {boolean} v
|
|
56
|
-
*/
|
|
57
|
-
set dispatching(v) {
|
|
58
|
-
console.warn('deprecated, flag should not be written to from outside of the signal');
|
|
59
|
-
this.writeFlag(SignalFlags.Dispatching, v);
|
|
60
|
-
}
|
|
61
|
-
|
|
37
|
+
flags = 0;
|
|
62
38
|
|
|
63
39
|
/**
|
|
64
40
|
*
|
|
@@ -120,14 +96,15 @@ export class Signal {
|
|
|
120
96
|
|
|
121
97
|
|
|
122
98
|
/**
|
|
123
|
-
*
|
|
124
|
-
* @param {function}
|
|
99
|
+
* Checks if a given signal handler is present or not
|
|
100
|
+
* @param {function} handler
|
|
101
|
+
* @param {*} [thisArg] if not present, will not be considered
|
|
125
102
|
* @returns {boolean}
|
|
126
103
|
*/
|
|
127
|
-
contains(
|
|
104
|
+
contains(handler, thisArg) {
|
|
128
105
|
const handlers = this.handlers;
|
|
129
106
|
|
|
130
|
-
const i = findSignalHandlerIndexByHandle(handlers,
|
|
107
|
+
const i = findSignalHandlerIndexByHandle(handlers, handler, thisArg);
|
|
131
108
|
|
|
132
109
|
return i !== -1;
|
|
133
110
|
}
|
|
@@ -149,7 +126,7 @@ export class Signal {
|
|
|
149
126
|
}
|
|
150
127
|
|
|
151
128
|
/**
|
|
152
|
-
*
|
|
129
|
+
* Handler will only be run once, it will be removed automatically after the first execution
|
|
153
130
|
* @param {function} h
|
|
154
131
|
* @param {*} [context]
|
|
155
132
|
*/
|
|
@@ -199,7 +176,10 @@ export class Signal {
|
|
|
199
176
|
}
|
|
200
177
|
|
|
201
178
|
/**
|
|
202
|
-
* Remove all handlers
|
|
179
|
+
* Remove all handlers.
|
|
180
|
+
* Please note that this will remove even all handlers, irrespective of where they were added from. If another script is attaching to the same signal, using this method will potentially break that code.
|
|
181
|
+
* For most use cases, prefer to use {@link remove} method instead, or make use of {@link SignalBinding} if you need to keep track of multiple handlers
|
|
182
|
+
* NOTE: Consider this method to be unsafe, only use it when you understand the implications
|
|
203
183
|
*/
|
|
204
184
|
removeAll() {
|
|
205
185
|
const handlers = this.handlers;
|
|
@@ -207,6 +187,7 @@ export class Signal {
|
|
|
207
187
|
}
|
|
208
188
|
|
|
209
189
|
/**
|
|
190
|
+
* NOTE: because of polymorphic call-site nature of this method, it's always better for performance to use monomorphic methods like `send0`, `send1` etc.
|
|
210
191
|
* @param {...*} args
|
|
211
192
|
*/
|
|
212
193
|
dispatch(...args) {
|
|
@@ -215,13 +196,8 @@ export class Signal {
|
|
|
215
196
|
return;
|
|
216
197
|
}
|
|
217
198
|
|
|
218
|
-
//mark dispatch process
|
|
219
|
-
this.setFlag(SignalFlags.Dispatching);
|
|
220
|
-
|
|
221
199
|
dispatchViaProxy(this.handlers, args);
|
|
222
200
|
|
|
223
|
-
//mark end of dispatch process
|
|
224
|
-
this.clearFlag(SignalFlags.Dispatching);
|
|
225
201
|
}
|
|
226
202
|
|
|
227
203
|
/**
|
|
@@ -594,14 +570,6 @@ export class Signal {
|
|
|
594
570
|
dispatch_stack_top = stack_pointer;
|
|
595
571
|
}
|
|
596
572
|
|
|
597
|
-
/**
|
|
598
|
-
* @deprecated do not use
|
|
599
|
-
* @returns {boolean}
|
|
600
|
-
*/
|
|
601
|
-
isDispatching() {
|
|
602
|
-
return this.getFlag(SignalFlags.Dispatching);
|
|
603
|
-
}
|
|
604
|
-
|
|
605
573
|
/**
|
|
606
574
|
*
|
|
607
575
|
* @param {Signal} other
|
|
@@ -632,7 +600,7 @@ Signal.prototype.isSignal = true;
|
|
|
632
600
|
*
|
|
633
601
|
* @param {SignalHandler[]} handlers
|
|
634
602
|
* @param {function} f
|
|
635
|
-
* @param thisArg
|
|
603
|
+
* @param {*} [thisArg]
|
|
636
604
|
* @returns {number} index of the handler, or -1 if not found
|
|
637
605
|
*/
|
|
638
606
|
export function findSignalHandlerIndexByHandle(handlers, f, thisArg) {
|
|
@@ -2,6 +2,14 @@
|
|
|
2
2
|
* Utility class for managing connection between listeners to signals
|
|
3
3
|
*/
|
|
4
4
|
export class SignalBinding {
|
|
5
|
+
/**
|
|
6
|
+
* Creates a {@link SignalBinding} and links it immediately. Utility method
|
|
7
|
+
* @param {Signal} signal
|
|
8
|
+
* @param {function} handler
|
|
9
|
+
* @param {*} [context]
|
|
10
|
+
* @return {SignalBinding}
|
|
11
|
+
*/
|
|
12
|
+
static bind(signal: Signal, handler: Function, context?: any): SignalBinding;
|
|
5
13
|
/**
|
|
6
14
|
*
|
|
7
15
|
* @param {Signal} signal
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SignalBinding.d.ts","sourceRoot":"","sources":["../../../../../src/core/events/signal/SignalBinding.js"],"names":[],"mappings":"AAAA;;GAEG;AACH;
|
|
1
|
+
{"version":3,"file":"SignalBinding.d.ts","sourceRoot":"","sources":["../../../../../src/core/events/signal/SignalBinding.js"],"names":[],"mappings":"AAAA;;GAEG;AACH;IA6EI;;;;;;OAMG;IACH,+DAFY,aAAa,CAUxB;IAjFD;;;;;;OAMG;IACH,8DA+BC;IA1CD,sBAEC;IAsBG;;;OAGG;IACH,eAAoB;IAEpB;;;OAGG;IACH,kBAAsB;IAEtB;;;OAGG;IACH,aAAsB;IAI1B;;;OAGG;IACH,aAOC;IAED;;;OAGG;IACH,eAOC;;CAkBJ"}
|
|
@@ -77,4 +77,21 @@ export class SignalBinding {
|
|
|
77
77
|
this.#linked = false;
|
|
78
78
|
this.signal.remove(this.handler, this.context);
|
|
79
79
|
}
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* Creates a {@link SignalBinding} and links it immediately. Utility method
|
|
83
|
+
* @param {Signal} signal
|
|
84
|
+
* @param {function} handler
|
|
85
|
+
* @param {*} [context]
|
|
86
|
+
* @return {SignalBinding}
|
|
87
|
+
*/
|
|
88
|
+
static bind(
|
|
89
|
+
signal, handler, context
|
|
90
|
+
) {
|
|
91
|
+
const r = new SignalBinding(signal, handler, context);
|
|
92
|
+
|
|
93
|
+
r.link();
|
|
94
|
+
|
|
95
|
+
return r;
|
|
96
|
+
}
|
|
80
97
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NodeDescription.d.ts","sourceRoot":"","sources":["../../../../../../src/core/model/node-graph/node/NodeDescription.js"],"names":[],"mappings":"AAyCA;IACI;;;OAGG;IACH,MAFU,MAAM,CAEN;IAEV;;;;;;OAMG;IACH,IAFU,MAAM,CAEO;IAEvB;;;OAGG;IACH,iBAFU,IAAI,EAAE,CAEL;IAEX;;;OAGG;IACH,YAFU,wBAAwB,EAAE,CAEpB;IAEhB;;OAEG;IACH;QACI;;;WAGG;4BADO,OAAO,IAAI,CAAC;QAGtB;;;WAGG;8BADO,OAAO,IAAI,CAAC;MAGxB;IAEF;;;;OAIG;IACH,4CAEC;IAED;;;OAGG;IACH,uBAEC;IAED;;;OAGG;IACH,sBAEC;IAED;;;;;;OAMG;IACH,sBALW,MAAM,QACN,qBAAqB,iBACrB,MAAM,GAAC,OAAO,GAAC,MAAM,GACnB,MAAM,CA0ClB;IAED;;;;OAIG;IACH,iBAHW,MAAM,GACJ,wBAAwB,CAiBpC;IAGD
|
|
1
|
+
{"version":3,"file":"NodeDescription.d.ts","sourceRoot":"","sources":["../../../../../../src/core/model/node-graph/node/NodeDescription.js"],"names":[],"mappings":"AAyCA;IACI;;;OAGG;IACH,MAFU,MAAM,CAEN;IAEV;;;;;;OAMG;IACH,IAFU,MAAM,CAEO;IAEvB;;;OAGG;IACH,iBAFU,IAAI,EAAE,CAEL;IAEX;;;OAGG;IACH,YAFU,wBAAwB,EAAE,CAEpB;IAEhB;;OAEG;IACH;QACI;;;WAGG;4BADO,OAAO,IAAI,CAAC;QAGtB;;;WAGG;8BADO,OAAO,IAAI,CAAC;MAGxB;IAEF;;;;OAIG;IACH,4CAEC;IAED;;;OAGG;IACH,uBAEC;IAED;;;OAGG;IACH,sBAEC;IAED;;;;;;OAMG;IACH,sBALW,MAAM,QACN,qBAAqB,iBACrB,MAAM,GAAC,OAAO,GAAC,MAAM,GACnB,MAAM,CA0ClB;IAED;;;;OAIG;IACH,iBAHW,MAAM,GACJ,wBAAwB,CAiBpC;IAGD;;;;;;OAMG;IACH,oDAHW,aAAa,GACX,MAAM,CA2BlB;IAED;;;;OAIG;IACH,eAHW,MAAM,GACJ,OAAO,CAuBnB;IAED;;;;OAIG;IACH,gBAHW,MAAM,GACJ,IAAI,GAAC,IAAI,CAgBrB;IAED;;;;OAIG;IACH,qBAHW,MAAM,GACL,IAAI,EAAE,CAwBjB;IAED;;;;OAIG;IACH,+BAHW,aAAa,GACZ,IAAI,EAAE,CAuBjB;IAED;;;;;OAKG;IACH,iCAJW,MAAM,aACN,aAAa,GACZ,IAAI,GAAC,SAAS,CAmBzB;IAED;;;OAGG;IACH,YAFa,IAAI,EAAE,CAIlB;IAED;;;;OAIG;IACH,cAHW,eAAe,GACb,OAAO,CAOnB;IAED,mBAEC;IAED;;;;MAMC;IAED;;;;;;OAMG;IACH;;;;qCAIC;IAKL;;;OAGG;IACH,4BAFU,OAAO,CAE0B;CAR1C;;;;qBAjYoB,WAAW;yCADS,yCAAyC;mBAH/D,kCAAkC;sCAEf,sCAAsC;8BAG9C,oBAAoB"}
|
|
@@ -185,6 +185,7 @@ export class NodeDescription {
|
|
|
185
185
|
* @param {DataType} type
|
|
186
186
|
* @param {String} name
|
|
187
187
|
* @param {PortDirection} direction
|
|
188
|
+
* @returns {number} ID of the newly created port
|
|
188
189
|
*/
|
|
189
190
|
createPort(type, name, direction) {
|
|
190
191
|
assert.defined(type, 'type');
|
|
@@ -237,6 +238,7 @@ export class NodeDescription {
|
|
|
237
238
|
}
|
|
238
239
|
}
|
|
239
240
|
|
|
241
|
+
// port not found
|
|
240
242
|
return false;
|
|
241
243
|
}
|
|
242
244
|
|