[jboss-dev-forums] [Design of JBossCache] - Re: POJOization of config elements

manik.surtani@jboss.com do-not-reply at jboss.com
Thu Oct 19 06:49:40 EDT 2006


How would implementation-specific values be set?  Again, using your BuddyLocator example, I presume this would be using BuddyLocatorConfig.getBuddyLocatorProperties()?  We're back to dealing with properties objects; how does this help the MC, except for the case of *known* setters/getters such as getBuddyLocatorClass()?

As an alternative approach (haven't spent *too* many cycles on this):

1)  Use a BuddyLocatorConfig that just contains *known* setters/getters, such as BuddyLocatorClass.

2)  If people wish to implement their own BuddyLocator, they would also provide their own sublass to BuddyLocatorConfig, adding their own custom setters/getters.

3)  The MC would still be able to inject this BLC subclass into the custom BL impl, since the interface methods comply.  The BL impl will be responsible for casting the BLC to the BLC subclass and extracting impl-specific configs.

Thoughts?

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3979326#3979326

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3979326



More information about the jboss-dev-forums mailing list