wt.series
Class LoadFileBasedSeries

java.lang.Object
  extended bywt.series.LoadFileBasedSeries

public class LoadFileBasedSeries
extends Object

Creates and persists a SeriesTemplate object based on an XML input file.

Usage:

 java wt.series.LoadFileBasedSeries  <-load | -read>    (absolute path)
 java wt.series.LoadFileBasedSeries c:\series.xml -load
 

The load option "-load" takes the XML file and stores to the database for use by FileBasedSeries.

The read option "-read" can be used to create an XML file containing the current FileBasedSeries stored in the database.



Supported API: true
Extendable: false

See Also:
ExportReportTemplate

Field Summary
private static String FILE_BASED_SERIES
           
private static String LOAD_FILE_DIR
           
private static String LOAD_OPTION
           
private static String RESOURCE
           
private static String STANDARD_ENCODING
           
static boolean VERBOSE
           
private static String WRITE_OPTION
           
private static String WT_HOME
           
 
Constructor Summary
LoadFileBasedSeries()
           
 
Method Summary
static boolean createFileBasedBegin(Hashtable fileFields, Hashtable cmd_line, Vector return_objects)
          Creates and persists a SeriesTemplate object.
static SeriesTemplate createSeriesTemplate(String a_xmlFileName)
          Processes "SeriesTemplate" from an XML load file.
private static SeriesTemplate findSeries()
           
private static String getValue(String name, Hashtable nv, Hashtable cmd_line, boolean required)
           
private static boolean isAdministrator()
           
private static String loadFile(String file_name)
           
static void main(String[] args)
           
private static void writeXmlDocument(String file, String xml)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FILE_BASED_SERIES

private static final String FILE_BASED_SERIES
See Also:
Constant Field Values

LOAD_OPTION

private static final String LOAD_OPTION
See Also:
Constant Field Values

WRITE_OPTION

private static final String WRITE_OPTION
See Also:
Constant Field Values

RESOURCE

private static String RESOURCE

STANDARD_ENCODING

private static final String STANDARD_ENCODING
See Also:
Constant Field Values

WT_HOME

private static final String WT_HOME

LOAD_FILE_DIR

private static final String LOAD_FILE_DIR

VERBOSE

public static final boolean VERBOSE
Constructor Detail

LoadFileBasedSeries

public LoadFileBasedSeries()
Method Detail

createSeriesTemplate

public static SeriesTemplate createSeriesTemplate(String a_xmlFileName)
                                           throws WTException
Processes "SeriesTemplate" from an XML load file.

Throws:
WTException

findSeries

private static SeriesTemplate findSeries()
                                  throws WTException
Throws:
WTException

loadFile

private static String loadFile(String file_name)
                        throws WTException
Throws:
WTException

writeXmlDocument

private static void writeXmlDocument(String file,
                                     String xml)
                              throws WTException
Throws:
WTException

isAdministrator

private static boolean isAdministrator()
                                throws WTException
Throws:
WTException

createFileBasedBegin

public static boolean createFileBasedBegin(Hashtable fileFields,
                                           Hashtable cmd_line,
                                           Vector return_objects)
Creates and persists a SeriesTemplate object.

Parameters:
fileFields - Hashtable containing the values read in from the input file.
Returns:
true if SeriesTemplate object is created, persisted, false otherwise
See Also:
wt.load.StandardLoadService.load, createFileBasedBegin

getValue

private static String getValue(String name,
                               Hashtable nv,
                               Hashtable cmd_line,
                               boolean required)
                        throws WTException
Throws:
WTException

main

public static void main(String[] args)
                 throws Exception
Throws:
Exception