com.ibm.commerce.marketingcenter.events.util

Class DBXMLFileWriter

  • java.lang.Object
    • com.ibm.commerce.marketingcenter.events.util.DBXMLFileWriter


  • public class DBXMLFileWriter
    extends java.lang.Object
    This class is used by ExportStats to connect to the database, create an XML file on the file system containing the content of a specified table.
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static java.lang.String COPYRIGHT
      IBM copyright notice field.
      static java.lang.String ENCODING
      Encoding used in the OutputStreamReader.
      static java.lang.String FILEPATH
      File path which is prepended to the name of the XML file.
    • Constructor Summary

      Constructors 
      Constructor and Description
      DBXMLFileWriter()
      Constructs a DBXMLFileWriter object.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      void writeFile(java.lang.String[] s)
      This method is used to connect to the database and write the content of a table into an XML file.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • COPYRIGHT

        public static final java.lang.String COPYRIGHT
        IBM copyright notice field.
        See Also:
        Constant Field Values
      • ENCODING

        public static final java.lang.String ENCODING
        Encoding used in the OutputStreamReader. Set to UTF-8.
        See Also:
        Constant Field Values
      • FILEPATH

        public static final java.lang.String FILEPATH
        File path which is prepended to the name of the XML file. Set to empty string.
        See Also:
        Constant Field Values
    • Constructor Detail

      • DBXMLFileWriter

        public DBXMLFileWriter()
        Constructs a DBXMLFileWriter object.
    • Method Detail

      • writeFile

        public void writeFile(java.lang.String[] s)
        This method is used to connect to the database and write the content of a table into an XML file. We use DBConnection to connect to the database. We use DBSql to query the database for a table and write the data into an XML file.
        Parameters:
        s - a Vector containing the following info: s[0] database type ; s[1] database name ; s[2] user id; s[3] user password; s[4] table name; s[5] name of the XML file.