puremvc
|
|
« Reply #1 on: May 02, 2009, 06:16:38 » |
|
Two ways to handle this:
1) Make bothe components implement the same interface. Then have the getter return the Interface rather than the class.
2) Keep a flag in the Mediator that says what kind of component is being held. Have two getters, one for each component type and referenct the appropriate one based on the flag.
Personally I'd opt for #1, and I'd write 2 mediators before doing #2
-=Cliff>
|