Paradyne SLM 5.5 Network Card User Manual


 
B. Using XML to Produce Reports
B-2
January 2002 7800-A2-GB32-00
Servlet Interface (SlvXmlServlet)
The XML report servlet can be found at:
/opt/pdn/OpenLane/OLServlets/pdn.webcgi.SlvXmlServlet
The SlvXmlServlet servlet accepts a report request in XML and generates a report
in a specified format. The output is sent to the browser window. XML output can
optionally be transformed into different formats by an XSL Transformation.
There is a sample Web page to demonstrate the use of the servlet at
/opt/pdn/OpenLane/samples/xml/reports/xmlentry.html
. You can
run the sample page from the URL
http://
your.domain.name
/OpenLane/xmlentry.html
when OpenLane is
running.
The easiest way to try the sample Web page is to open an XML report request file,
select and copy the text, and paste it into the Web page. Sample XML report
requests can be found in the following directories:
/opt/pdn/OpenLane/samples/xml/reports/DeviceReports/Requests
/opt/pdn/OpenLane/samples/xml/reports/SlvReports/Requests
Writing an Interface to the Servlet
The servlet expects a HyperText Transfer Protocol (HTTP) post with up to three
parameters:
XmlReportRequest.
The first and only mandatory parameter is
XmlReportRequest, which contains the report request in XML format.
OutputClassOrMime.
The post may also contain a parameter called
OutputClassOrMime, which tells a Web browser how to interpret the reply for
viewing. This usually matches the output type specified in the report request,
but does not have to. For example, you may want to view an HTML/JavaScript
report as ASCII by using text/plain as the Multipurpose Internet Mail Extension
(MIME) type. The normal reply types for the supported report formats are
shown in the following table:
XslRequest.
When the requested report output type is XML, the post
optionally may also contain a parameter called XslRequest, which contains an
XSL Transformation to apply.
Output Default MIME Type
DEFAULT (not specified)
and errors
text/plain
XML text/xml
HTML/JavaScript text/html
CSV text/plain