MCPcopy Create free account
hub / github.com/PageLeay/celestial-runtime / forEachEvent

Method forEachEvent

lib.commonjs/abi/interface.js:564–571  ·  view source on GitHub ↗

* Iterate over all events, calling %%callback%%, sorted by their name.

(callback)

Source from the content-addressed store, hash-verified

562 * Iterate over all events, calling %%callback%%, sorted by their name.
563 */
564 forEachEvent(callback) {
565 const names = Array.from(this.#events.keys());
566 names.sort((a, b) => a.localeCompare(b));
567 for (let i = 0; i < names.length; i++) {
568 const name = names[i];
569 callback((this.#events.get(name)), i);
570 }
571 }
572 /**
573 * Get the [[ErrorFragment]] for %%key%%, which may be an error
574 * selector, error name or error signature that belongs to the ABI.

Callers

nothing calls this directly

Calls 1

fromMethod · 0.45

Tested by

no test coverage detected