Nov 16, 2011 at 5:30 PM
Edited Nov 16, 2011 at 5:37 PM
I have a question regarding the usage of CompositeCommand.
Let me describe the situation:
I have a module that is managing the workspaces (WorkspaceManager). A workspace is a folder that contains several files. These files are associated with various child modules. A workspace can be loaded, saved, etc. Obviously, the child modules are directly
impacted by a workspace loading operation (they have to load their own files from the folder).
In order to address this need, I was thinking of using CompositeCommand: the WorkspaceManager is exposing the load/save CompositeCommands. The child modules are registering their child DelegateCommand (load / save) with the CompositeCommands of the WorkspaceManager
in order to do the specific loading.
Another option can consist in using events (shared service events or through EventAggregator) but it seems less adapted to this situation (in particular because it's asynchronous).
What is your thoughts on this issue?
Thanks a lot,