org.jSyncManager.API.Conduit.Tools

Class ToDoListDBXML


public class ToDoListDBXML
extends DLPRecordXML

This is a synchronization JConduit for ax XML document from the ToDoListDB 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
RECORDNAME
static String
XMLNAME
JSXMLElement document

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

RECORDNAME, XMLNAME

Constructor Summary

ToDoListDBXML()
Create new JSXMLDocument with default name and ToDoListDB DTD entity.
ToDoListDBXML(InputStreamReader inputfile)
Create new ToDoListDBScanner with InputStreamReader stream input.
ToDoListDBXML(JSXMLDocument document)
Create new JSXMLDocument with given JSXMLDocument.
ToDoListDBXML(ToDoListRecord rec)
Create new JSXMLDocument with given ToDoListRecord.

Method Summary

String
getDTD()
Get the complete DTD for this database type.
ToDoListRecord
insertRecord(ToDoListRecord rec)
Insert ToDoListRecord 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

RECORDNAME

public static String RECORDNAME

XMLNAME

public static String XMLNAME
JSXMLElement document

Constructor Details

ToDoListDBXML

public ToDoListDBXML()
Create new JSXMLDocument with default name and ToDoListDB DTD entity.

ToDoListDBXML

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

ToDoListDBXML

public ToDoListDBXML(JSXMLDocument document)
Create new JSXMLDocument with given JSXMLDocument.
Parameters:
document - The JSXMLDocument to be read and input.

ToDoListDBXML

public ToDoListDBXML(ToDoListRecord rec)
Create new JSXMLDocument with given ToDoListRecord.
Parameters:
rec - ToDoListRecord

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 ToDoListRecord insertRecord(ToDoListRecord rec)
Insert ToDoListRecord into XML Document.
Parameters:
rec - ToDoListRecord input.
Returns:
Return the ToDoListRecord for further processing.

readDocument

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