
org.enhydra.xml.xmlc.deferredparsing.package.html Maven / Gradle / Ivy
The newest version!
package: org.enhydra.xml.xmlc.deferredparsing
org.enhydra.xml.xmlc.deferredparsing
provides support for deferred
parsing of *ML objects.
"Deferred parsing" means that no support for creating a DOM
is compiled into the generated class. Instead, the generated class
obtains the DOM from a {@link org.enhydra.xml.xmlc.deferredparsing.DocumentLoader}
at creation time.
The main indications for using deferred parsing are:
-
An environment where the *ML templates change frequently
(example: A personalized website where the layout is controlled by
an external CMS). Using deferred parsing instead of recompilation
gives the advantage of shorter turnaround times on template changes
because only the parse and edit steps are needed and the (expensive)
recompile can be omitted.
-
An environment with a large number of XMLC compiled pages. Using
deferred parsing here avoids the typical "fat" XMLC classes
(i.e. classes with a huge number of string constants and the big
method bodies used in the DOM generation code found in normal XMLC
classes). This gets around a problem with at least SUN JDK 1.3.x,
where only a limited number of "fat" classes can be loaded before
all further attempts fail with an OutOfMemoryError in {@link
java.lang.ClassLoader#defineClass}. The number of "fat" XMLC classes that can
be loaded seems to be proportional to the size of the individual *ML
templates and is completely independent of memory (heap and stack size) limits
for the virtual machine.
© 2015 - 2025 Weber Informatics LLC | Privacy Policy