org.jSyncManager.API.Conduit.Tools

Class ExpenseDBXML


public class ExpenseDBXML
extends DLPRecordXML

This is a synchronization JConduit for ax XML document from the ExpenseDB database. Each element in the record will be a double-quoted String, escaped if necessary.
See Also:
JSXMLDocument, JSXMLElement, JSXMLDate, DLPRecordXML

Field Summary

static String
XMLNAME
org.w3c.dom.Document document

Fields inherited from class org.jSyncManager.API.Conduit.Tools.DLPRecordXML

RECORDNAME, XMLNAME

Constructor Summary

ExpenseDBXML()
Create new JSXMLDocument with default name and ExpenseDB DTD entity.
ExpenseDBXML(InputStreamReader inputfile)
Create new ExpenseDBScanner with InputStreamReader stream input.
ExpenseDBXML(ExpenseRecord rec)
Create new JSXMLDocument with given ExpenseRecord.
ExpenseDBXML(org.jdom.Document document)
Create new JSXMLDocument with given JSXMLDocument.

Method Summary

String
getDTD()
Get the complete DTD for this database type.
ExpenseRecord
insertRecord(ExpenseRecord rec)
Insert ExpenseRecord into XML Document.
void
readDocument(InputStreamReader inputfile)
Read JSXMLDocument through InputStreamReader and parse into XML Document.

Methods inherited from class org.jSyncManager.API.Conduit.Tools.DLPRecordXML

getDTD, insertRecord, readDocument

Methods inherited from class org.jSyncManager.API.Conduit.Tools.JSXMLDocument

getDTD, readDocument, readDocument, readDocument, readDocument, setDTD, setDocument, writeDocument

Field Details

XMLNAME

public static String XMLNAME
org.w3c.dom.Document document

Constructor Details

ExpenseDBXML

public ExpenseDBXML()
Create new JSXMLDocument with default name and ExpenseDB DTD entity.

ExpenseDBXML

public ExpenseDBXML(InputStreamReader inputfile)
            throws org.jdom.JDOMException,
                   IOException
Create new ExpenseDBScanner with InputStreamReader stream input.
Parameters:
inputfile - InputStreamReader

ExpenseDBXML

public ExpenseDBXML(ExpenseRecord rec)
Create new JSXMLDocument with given ExpenseRecord.
Parameters:
rec - ExpenseRecord

ExpenseDBXML

public ExpenseDBXML(org.jdom.Document document)
Create new JSXMLDocument with given JSXMLDocument.
Parameters:
document - The JSXMLDocument to be read and input.

Method Details

getDTD

public String getDTD()
Get the complete DTD for this database type.
Overrides:
getDTD in interface DLPRecordXML
Returns:
String containing complete DTD, delimited by System.Properties.line.separator

insertRecord

public ExpenseRecord insertRecord(ExpenseRecord rec)
Insert ExpenseRecord into XML Document.
Parameters:
rec - ExpenseRecord input.
Returns:
Return the ExpenseRecord for further processing.

readDocument

public void readDocument(InputStreamReader inputfile)
            throws org.jdom.JDOMException,
                   IOException
Read JSXMLDocument through InputStreamReader and parse into XML Document.
Overrides:
readDocument in interface JSXMLDocument
Parameters:
inputfile - InputStreamReader input.