You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by Apache Wiki <wi...@apache.org> on 2005/06/02 09:26:22 UTC
[Myfaces Wiki] Update of "ComponentPack" by WernerPunz
Dear Wiki user,
You have subscribed to a wiki page or wiki category on "Myfaces Wiki" for change notification.
The following page has been changed by WernerPunz:
http://wiki.apache.org/myfaces/ComponentPack
New page:
= How to build a component pack =
== Introduction ==
Component packs are a way to capsule components into a single jar library. The user can download it, dump it into the WEB-INF/lib and start to use the components instantly by including the tld in the page header.
== How to create one ==
A component pack is a single jar file with the class files for the components, a single faces-conf.xml with the needed description for the JSF system and the TLDs for the tag lib inclusion.
There is an enforced filestructure every component pack has to follow.
{{{
/META-INF
/<your class packages>
}}}
The File structure can be split into following subfiles and subdirectories
{{{
/META-INF
/META-INF/faces-config.xml
/META-INF/thetld.tld
/META-INF/<whatever is needed also by the files (additional xml files entity files etc)>
/<packages with the class files for the components>
}}}
This structure has to be jarred with your preferred jar tool and the component pack should work as described above.
"Note" there is a huge difference to runtime jar files, you dont need a manifest file to make a working jar, dumping the config file stuff into /META-INF and packaging it with the tool of your choice (plain jar, ant, even a jar export from eclipse) works in any case.