@woosh/meep-engine 2.47.13 → 2.47.15
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 +10 -1
- package/build/meep.min.js +1 -1
- package/build/meep.module.js +10 -1
- package/package.json +1 -1
- package/src/core/IdPool.js +10 -1
- package/src/core/json/abstractJSONSerializer.js +1 -1
- package/src/core/model/node-graph/NodeGraph.js +23 -6
- package/src/core/model/node-graph/node/NodeInstance.d.ts +4 -0
package/build/meep.cjs
CHANGED
|
@@ -117654,12 +117654,21 @@ function IdPool() {
|
|
|
117654
117654
|
this.bitSet = new BitSet();
|
|
117655
117655
|
}
|
|
117656
117656
|
|
|
117657
|
+
/**
|
|
117658
|
+
* Looks up next available ID without reserving it
|
|
117659
|
+
* If you want to also reserve the ID - use {@link get} instead
|
|
117660
|
+
* @returns {number}
|
|
117661
|
+
*/
|
|
117662
|
+
IdPool.prototype.peek = function () {
|
|
117663
|
+
return this.bitSet.nextClearBit(0);
|
|
117664
|
+
};
|
|
117665
|
+
|
|
117657
117666
|
/**
|
|
117658
117667
|
*
|
|
117659
117668
|
* @returns {number}
|
|
117660
117669
|
*/
|
|
117661
117670
|
IdPool.prototype.get = function () {
|
|
117662
|
-
const bitIndex = this.
|
|
117671
|
+
const bitIndex = this.peek();
|
|
117663
117672
|
|
|
117664
117673
|
this.bitSet.set(bitIndex, true);
|
|
117665
117674
|
|