Class XMLOIFormatter

java.lang.Object
com.nt.udc.ndk.node.OIFileFormatter
com.nt.udc.oi.node.xml.XMLOIFormatter
Direct Known Subclasses:
XMLOISimpleFormatter

public abstract class XMLOIFormatter extends OIFileFormatter
This class is responsible for properly formatting the output files of the XML OI node. For each output file created, the initial entry into the file will be a header line detailing the fields contained in the following lines.
Since:
JDK1.2.2
  • Constructor Details

    • XMLOIFormatter

      public XMLOIFormatter(LoggerIfc logr, OIFileWriter oiFileWriter)
      Constructor
      Parameters:
      logr - LoggerIfc() object providing access to the node's log file
      oiFileWriter - OIFileWriter() object responsible for file output and managing the output files.
  • Method Details

    • writeToFile

      public void writeToFile(DCFieldContainer record) throws IOException
      This method will write the appropriately formatted data contained within the DCFieldContainer to the output file. When necessary, a file header line will also be written.
      Specified by:
      writeToFile in class OIFileFormatter
      Throws:
      IOException
    • fileOpening

      public void fileOpening(DCFieldContainer rec)
      This is a callback from the base-class. The call is made right after opening an output file. Here it is used to write out a header.
      Overrides:
      fileOpening in class OIFileFormatter
    • fileClosing

      public void fileClosing(DCFieldContainer rec)
      This is a callback from the base-class. The call is made just before closing an output file. Here it is used to write out a trailer.
      Overrides:
      fileClosing in class OIFileFormatter
    • getRecordString

      protected abstract String getRecordString(DCFieldContainer record)