Class OracleDBToXML

java.lang.Object
  |
  +--OracleDBToXML

public class OracleDBToXML
extends java.lang.Object

Creates an XML Document from a table in the database.

The XML document will contain the structure of the database table, i.e. the fields and their datatypes and all the rows in the table.


Constructor Summary
OracleDBToXML(java.lang.String url, java.lang.String user, java.lang.String password)
          Returns an object initialized with the Connection object constructed by the arguments.
 
Method Summary
 void convertDBtoXML(java.lang.String table, boolean addStructure)
          Creates an XML file from the database table.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OracleDBToXML

public OracleDBToXML(java.lang.String url,
                     java.lang.String user,
                     java.lang.String password)
Returns an object initialized with the Connection object constructed by the arguments. Creates the object with the database parameters specified.
Parameters:
url - database url to be used.
user - user name to connect to the database.
password - password to connect to the database.
Method Detail

convertDBtoXML

public void convertDBtoXML(java.lang.String table,
                           boolean addStructure)
Creates an XML file from the database table. Creates an XML file of the same name as the name of the table. The XML file generated contains all the rows present in the table and also the structure (fieldnames and datatypes) depending on the value of the addStructure parameter.
Parameters:
table - table name to generate the XML file of the same name.
addStructure - flag to specify whether the table structure that is the field names and the datatypes are to be included or not.