[jboss-dev-forums] [Design the new POJO MicroContainer] - Re: Generated Classes not found if they do not match any of
adrian@jboss.org
do-not-reply at jboss.com
Tue Mar 10 12:15:49 EDT 2009
"kabir.khan at jboss.com" wrote : Then the plan is to use the global capabilities provider in Module when determining the capabilities.
|
There's no need to add extra state to the Module. Its shared information.
You should just delegate to the domain which will in turn delegate to the ClassLoading.
That way we can also have "Global capabilities" at the domain level in future if we want.
They can be package private methods.
In Module.java
| /**
| * Get the capabilities.
| *
| * @return the capabilities.
| */
| public List<Capability> getCapabilities()
| {
| // Have we already worked this out?
| if (capabilities != null)
| return capabilities;
|
| // Are there any configured ones?
| List<Capability> capabilities = determineCapabilities();
|
| // Use the defaults
| if (capabilities == null)
| capabilities = defaultCapabilities();
|
| HERE!!!!
|
| // Merge in the global capabilities
| capabilities = getDomain().mergeGlobalCapabilities(capabilites); // Which does classloading.mergeGlobalCapabilies(capabilities)
|
| // Cache it
| this.capabilities = capabilities;
| return capabilities;
| }
|
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4216650#4216650
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4216650
More information about the jboss-dev-forums
mailing list