|
From: Juergen H. <ju...@in...> - 2005-03-18 22:32:08
|
Guys,
Do we really want to ship this out-of-the-box in Spring core? This is nearly
1.8 MB of additional third-party jars, half of it cause by the great XMLC
decision to depend on a repackaged Xerces version...
If I remember correctly, that was also the original rationale for *not*
including it in Spring in the first place. I think that reason is still
valid, in particular due to the fact that the AbstractXmlcView base class is
so extremely thin.
BTW, we don't need an XmlcLoaderServlet or XmlcLoaderListener.
XMLCContext.getContext(servletContext) creates a new XMLCContext on first
access but then returns the existing instance. No need to initialize this in
a separate servlet or listener!
Effectively, a custom View implementation that uses XMLC could look as
follows - without any XMLC-specific base class shipped in Spring:
public abstract class MyXmlcView extends AbstractView {
protected void renderMergedOutputModel(
Map model, HttpServletRequest request, HttpServletResponse response)
throws Exception {
this.xmlcContext = XMLCContext.getContext(getServletContext());
OutputOptions oo = new OutputOptions();
XMLObject xo = // creating the XMLObject from the model
response.setContentType(getContentType());
this.xmlcContext.writeDOM(request, response, oo, xo);
}
}
Given how concise this, it seems to me that we really don't need to ship an
AbstractXmlcView class for this. Showing that skeleton code in the reference
docs or on the Wiki should be enough...
Juergen
-----Original Message-----
From: spr...@li...
[mailto:spr...@li...]On Behalf
Of Rob Harrop
Sent: Thursday, March 17, 2005 7:34 PM
To: spr...@li...
Subject: [Springframework-developer] XMLC Support
All,
I just committed basic XMLC support to CVS. This is based heavily on the
work Rod did in his original book.
Let me have your thoughts.
Rob
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Springframework-developer mailing list
Spr...@li...
https://lists.sourceforge.net/lists/listinfo/springframework-developer
|