You can find the full source code for this website in the Seam package in the directory /examples/wiki. It is licensed under the LGPL.
| Online: | 4 Members of 12451 |
| Forum: Seam Users |
04. Oct 2008, 23:33 America/New_York | Link |
Currently it is possible to have a global pages.xml file or a .page.xml per page.
I would like to be able to define multiple meta-inf/pages.xml and have them all merged similar to the way meta-inf/components.xml works.
It looks like I could just modify Pages.initialize() to work similar to the way Initialization.initComponentsFromXmlDocuments() works something like this:
public void initialize() {
// leave existing impl
for (String resource: resources) {
InputStream stream = ResourceLoader.instance().getResourceAsStream(resource);
parse(stream);
}
// add adding approach
Enumeration<URL> resources = Thread.currentThread().getContextClassLoader().getResources("META-INF/pages.xml");
while (resources.hasMoreElements()) {
URL url = resources.nextElement();
parse(url.openStream());
}
}
Does anyone see any unintended side effects or problems with doing this?
File a feature request with a patch :-)
Read about how to report a bug.
Right now you can specify multiple pages.xml files and have them merged.
Check out this link to the old Seam forums :
Multiple Pages.xml
---------------- www.andygibson.net ----------------
My blog for my Open Source Projects, Tutorials and Java EE 6 Maven Archetypes
Connect with me on Twitter or LinkedIn
Oh, and this goes in components.xml
Cheers,
Andy
---------------- www.andygibson.net ----------------
My blog for my Open Source Projects, Tutorials and Java EE 6 Maven Archetypes
Connect with me on Twitter or LinkedIn
Thanks for pointing out the additional multiple pages configuration feature. That helps a little but doesn't cover all of my goals.
Here is another posting that covers the whole plugin goal I am after:
Seam Plugins
Here are the JIRA features/patches I created:
https://jira.jboss.org/jira/browse/JBSEAM-3509
https://jira.jboss.org/jira/browse/JBSEAM-3510