Class FileWritingTemplate

java.lang.Object
edu.sc.seis.sod.status.Template
edu.sc.seis.sod.status.FileWritingTemplate
All Implemented Interfaces:
GenericTemplate, Runnable
Direct Known Subclasses:
EventStatusTemplate, IndexTemplate, NetworkInfoTemplate, WaveformStatusTemplate

public class FileWritingTemplate extends Template implements GenericTemplate, Runnable
  • Constructor Details

  • Method Details

    • testOutputLoc

      public static String testOutputLoc(String loc) throws IOException
      Throws:
      IOException
    • write

      public void write()
    • getResult

      public String getResult()
      Specified by:
      getResult in interface GenericTemplate
    • textTemplate

      protected Object textTemplate(String text)
      Description copied from class: Template
      returns an object of the template type that this class uses, and returns the passed in text when the getResult method of that template type is called
      Specified by:
      textTemplate in class Template
    • getOutputLocation

      public String getOutputLocation()
    • getFilename

      public String getFilename()
    • getOutputDirectory

      protected File getOutputDirectory()
    • getTemplate

      protected Object getTemplate(String tag, Element el) throws ConfigurationException
      Description copied from class: Template
      if this class has an template for this tag, it creates it using the passed in element and returns it. Otherwise it should return the superclass implementation of the getCommonTemplate method. Though no harm will come from merely returning null, they won't benefit from the wisdom and extra tags provided by their elder classes.
      Overrides:
      getTemplate in class Template
      Throws:
      ConfigurationException
    • run

      public void run()
      Specified by:
      run in interface Runnable
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • write

      public static void write(String outputLocation, String output)
    • getBaseDirectoryName

      public static String getBaseDirectoryName()