Multicast function
Functions are the foundation of events, and events can have multiple subscribers, hence the need for multicast functions.
const multicastFunction = new MulticastFunction<() => void>();
const func = () => {
};
multicastFunction.add(func);
multicastFunction.invoke();
For more examples, please refer to the unit tests.