If I have a command called 'SetReadyOnlyMode', is it OK for me to access public methods on mediators from that command and pass some properties? Or should I be firing another batch of notifications from that command to be picked up by the mediators?
The component views are disabled depending on some values in different proxies, so in my command I want to do this:
if (!userProxy.getAlwaysShowToolbars()){
toolbarMediator1.hideView();
toolbarMediator2.hideView();
}
if (userProxy.contactListContains(friendProxy.friendIDs)){
friendListMediator.showView(friendProxy.friendIDs);
} else { // ... hide friendList ... }
Does this seem a good way to do it? Can commands 'directly' interact with mediators like this, and pass arguments etc.? Otherwise I'm worried I'll have bloated code as a result of too many notification string constants all with similar tasks.
Many thanks for any help!