This content has been marked as final.
Show 4 replies
-
1. Re: Need seam to load XXX.jar!/META-INF/pages.xml
pmuir Jan 29, 2008 7:03 AM (in response to zjsun)You can specify the pages.xml files to use in components.xml
<navigation:pages resources> <value>/WEB-INF/pages.xml</value> <value>/META-INF/pages.xml</value> </navigation:pages>
-
2. Re: Need seam to load XXX.jar!/META-INF/pages.xml
zjsun Feb 2, 2008 9:04 AM (in response to zjsun)"pete.muir@jboss.org" wrote:
You can specify the pages.xml files to use in components.xml<navigation:pages resources> <value>/WEB-INF/pages.xml</value> <value>/META-INF/pages.xml</value> </navigation:pages>
not work yet, by config "/META-INF/pages.xml", only one jar's pages.xml is loaded, not all jar's, because i have multiple jar files contains the "/META-INF/pages.xml" file. Any idea? -
3. Re: Need seam to load XXX.jar!/META-INF/pages.xml
pmuir Feb 2, 2008 9:47 AM (in response to zjsun)Call your pages.xml files unique names - like META-INF/foo-pages.xml
or, you could submit a patch for this. I would consider adding this functionality to Seam. -
4. Re: Need seam to load XXX.jar!/META-INF/pages.xml
zjsun Feb 2, 2008 11:40 PM (in response to zjsun)@Scope(ScopeType.APPLICATION) @BypassInterceptors @Name("org.jboss.seam.navigation.pages") @Install(precedence = Install.APPLICATION) public class EpstarPages extends SeamPages { @Override public void initialize() { super.initialize(); // åŠ è½½ XXX.jar!/META-INF/pages.xml for (URL url : ResourcesUtils .findClassLoaderResources("/META-INF/pages.xml")) { try { InputStream stream = url.openStream(); parse(stream); } catch (IOException e) { } } } }
as org.jboss.seam.navigation.Pages made "initialize" method with "private", i just create new SeamPages class which extends org.jboss.seam.navigation.Pages, by coping all Pages class's source, and make "initialize" method with "public".
right?