|
|
Sponsor |
Re: XMLC 2.2 Alpha 2 and Examples released (Download location): msg#00131java.enhydra.xmlc
Here are some slight modifications to the example app make things work for both Unix and Windows users out of the box (attached zip file). I've included only the files that were modified. Should be obvious where they go. Jake At 02:34 PM 11/30/2002 -0600, you wrote: Hi David,http://homepage.mac.com/taweili/XMLC.html David On Thursday, Nov 28, 2002, at 01:31 Asia/Shanghai, David Li wrote: The release fixes several bugs and updates several helpers classes to ease the integration of XMLC in a servlet containers. This new release contains an example webapp using the new reloading for XMLC which can be easily deploy under Tomcat containers. (nothing Tomcat specific about it but I just have time to test it on Tomcat.) The attached is the README for the example. David --- This is an example program to demo how to use XMLC in a Servlet. The example is use Tomcat 4.1.12, other containers have not been tested. Configuration: Copy the 'build.properties.examples' to 'build.properties' and edit the two properties according to your local setup. Build: Simply 'ant' Running: A script run-tomcat.sh will be created in this directory. Just type $ ./run-tomcat.sh Accessing the demo: The demo servlet is located at /xmlc/ReloadTest and can be access with http://localhost:8080/xmlc/ReloadTest The servlet expects a 'docClass' or a 'doc' parameter pointing to the document to be retrived. The 'docClass' parameter points to a fully qualified classname of a XMLC compiled page. Currently available document class are: Compiled from res/pkg, xmlc.demo.test01HTML xmlc.demo.test02HTML Compiled from res/page xmlc.page.page01HTML xmlc.page.page02HTML Example: http://localhost:8080/xmlc/ReloadTest?docClass=xmlc.page.page02HTML The 'doc' parameter points to a relative path name of a page to be compiled and retrieved. These pages do not have to be precompiled by XMLC in order to be loaded and use as a XMLObject. Currently available documents are: dyna/dyna01.html dyna/dyna02.html The following pages are the source of the above compiled XMLC class. They can be loaded with the following path name. However, loading them will only return a XMLObject, not the above named class/interface. page/page01.html page/page02.html pkg/xmlc/demo/test01.html pkg/xmlc/demo/test02.html Examples: http://localhost:8080/xmlc/ReloadTest?doc=dyna/dyna01.html ReloadTest source: The source code for ReloadTest servlet is located under src/xmlc/demo/ReloadTest.java. This file demostracted the use of the following class: org.enhydra.xml.xmlc.servlet.XMLCContext: This is a convenient class to integrate XMLC with Servlet. It configure the XMLCFactory with parameter from Servlet context. In this demo, the configuration is done in res/webapps/xmlc/WEB-INF/web.xml for the XMLC WebApp. The document on the parameters can be found in the javadoc of org.enhydra.xml.xmlc.servlet.XMLCContext. This class also provides methods to serialize of XMLObject object to the response with various of configuration. org.enhydra.xml.xmlc.deferredparsing.XMLCDeferredParsingFactory: The dynamic page loading using method the createFromFile which is specific to this call and not in XMLCFactory. The use of this method is demo here. _______________________________________________ XMLC mailing list XMLC@xxxxxxxxxxx http://www.enhydra.org/mailman/listinfo.cgi/xmlc _______________________________________________ XMLC mailing list XMLC@xxxxxxxxxxx http://www.enhydra.org/mailman/listinfo.cgi/xmlc </blockquote></x-html>
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | problems with XMLCVersion.java, Mark Diekhans |
|---|---|
| Previous by Thread: | Re: XMLC 2.2 Alpha 2 and Examples released (Download location), Jacob Kjome |
| Next by Thread: | problems with XMLCVersion.java, Mark Diekhans |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
Free MagazinesCisco NewsReceive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business. subscribe Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field. subscribe The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business. subscribe Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company. subscribe Total Telecom Total Telecom is "The Economist of the communications industry". subscribe |
Home | sitemap
| advertise | OSDir is
an inevitable website.
|