|
OpMath | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--com.opmath.util.dmldoc.DMLDocBlock
|
+--com.opmath.util.dmldoc.DMLDoc
The Document Object Model (DOM) for the template.
DMLDoc provides a simple, efficient and highly-functional method
for generating dynamic Web pages, or other dynamic SGML documents. This enables
a flexible approach to constructing Web sites using Java Servlets, Enterprise
Java Beans, and any other appropriate Java technology. The approach is independent
of the choice of Web server, Java applications server or server-side database.
DMLDoc provides the highest-level view of the
com.opmath.util.dmldoc structures. This includes the DOM, together
with a ComparableTable for holding tabluar data, known as the
DMLDoc model.
Copyright: (c) 2002 The Open Math Company Limited
The Terms of Distribution of this software are stipulated in the javadoc Overview for this project.
DMLDocBlock,
DMLDocText| Field Summary | |
ComparableTable |
model
|
| Fields inherited from class com.opmath.util.dmldoc.DMLDocBlock |
CMD_ENDIF, CMD_ENDLOOP, CMD_IF, CMD_IFDATA, CMD_IFNODATA, CMD_IFNOT, CMD_LOOP, CMD_SUB, DELIMITERS, EOL |
| Constructor Summary | |
DMLDoc(BufferedReader viewReader)
Constructs a DMLDoc for a given BufferedReader. |
|
DMLDoc(InputStream viewStream)
Constructs a DMLDoc for a given InputStream. |
|
DMLDoc(String viewPath,
String viewFile)
Constructs a DMLDoc for the text found in the named file. |
|
| Method Summary | |
String |
view()
Returns a String representaion of this DMLDoc
instance, with the various SUBs, LOOPs and IF / IFNOT / IFDATAFOR / IFNODATAFOR
elements processed, as determined by the contents of the model. |
| Methods inherited from class com.opmath.util.dmldoc.DMLDocBlock |
parse, toString, view, view, viewNames, viewNames, viewWithException |
| Methods inherited from class java.lang.Object |
|
| Field Detail |
public ComparableTable model
| Constructor Detail |
public DMLDoc(BufferedReader viewReader)
throws DMLDocBuildException
Constructs a DMLDoc for a given BufferedReader.
It is anticipated that DMLDoc(String, String) will be the
most common way in which DMLDoc instances are created.
inputText - the BufferedReader for the template.DMLDocBuildException - An exception thrown if
the template text contained ill-formed commands.DMLDoc(String, String)
public DMLDoc(InputStream viewStream)
throws DMLDocBuildException
Constructs a DMLDoc for a given InputStream.
It is anticipated that DMLDoc(String, String) will be the
most common way in which DMLDoc instances are created.
inputStrm - the InputStream for the template.DMLDocBuildException - An exception thrown if
the template text contained ill-formed commands.DMLDoc(String, String)
public DMLDoc(String viewPath,
String viewFile)
throws DMLDocBuildException
Constructs a DMLDoc for the text found in the named file.
This node will be the root of a new DMLDoc.
It is anticipated that this will be the most common way in which
DMLDoc instances are created.
pathName - the path the template file (with the
trailing directory delimiter).fileName - the name for the template file, with suffix.DMLDocBuildException - an exception thrown if
the template file was missing or contained ill-formed commands.| Method Detail |
public String view()
Returns a String representaion of this DMLDoc
instance, with the various SUBs, LOOPs and IF / IFNOT / IFDATAFOR / IFNODATAFOR
elements processed, as determined by the contents of the model.
If the model is malformed, view() attempts to return
a String containing an SGML-formatted report detailing the cause
of the problem. The template resource for this report is held at
com.opmath.util.dmldoc.tpl_DMLDocWriteException.html. This
template may be edited, but all of its SUB .. commands should remain
unaltered.
NOTE: If com.opmath.util.dmldoc.tpl_DMLDocWriteException.html
is not found, or is malformed, then view() reports to
System.err and returns an empty String.
String containing the instantiated SGML template.
|
OpMath | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||