I got 3 modules called A, B, C.
A fires an event x, B fires an event y.
C will be listened these two events x and y.
In case of event x => event handler called XEventHandler => Which will generate object A.
In case of event y => event handler called YEventHandler
In YEventHandler, Object A will be used. So I need some way to handle this so that:
1. If Object A is created => YEventHanlder will be executed if module C catch y Event
2. If Object A is not created yet (x event haven't been fired yet or the process of creating object A hasn't finished yet) => YEventHanlder need to wait until object A is ready and continue.
How can I solve this issue?
Thanks for such a cool community.