Class ReportBuilder

java.lang.Object
ca.phon.query.report.ReportBuilder
Direct Known Subclasses:
CSVReportBuilder

@Deprecated public abstract class ReportBuilder extends Object
Deprecated.
An interface for building reports based on a report design and given search data. Each type of report output (CSV, excel, etc.) requires an implementation of this interface.
  • Field Details

    • TEMP_PROJECT

      public static final String TEMP_PROJECT
      Deprecated.
      Temporary project. This is the project the report builder should read the result set files from. If null, result sets will be read from default project. Type: IPhonProject, default: null
      See Also:
    • CANCEL_BUILD

      public static final String CANCEL_BUILD
      Deprecated.
      Property for halting the report building process. Useful if using this class in a thread with the ability to cancel the operation. (default:false)
      See Also:
  • Constructor Details

    • ReportBuilder

      public ReportBuilder()
      Deprecated.
  • Method Details

    • putProperty

      public void putProperty(String key, Object val)
      Deprecated.
    • getProperty

      public Object getProperty(String key)
      Deprecated.
    • getPropertyNames

      public String[] getPropertyNames()
      Deprecated.
      Returns a list of property names used for configuring the builder. The properties are presented as options in the report wizard.
      Returns:
      propNames
    • getPropertyClass

      public Class<?> getPropertyClass(String propName)
      Deprecated.
      Returns the value type for the given property name. NOTE: Only Boolean and String values are supported by the report wizard.
      Parameters:
      propName -
      Returns:
      the class of the property value
    • getPropertyMessage

      public String getPropertyMessage(String propName)
      Deprecated.
      Returns the UI message associated with a property name returned by getPropertyNames()
      Parameters:
      propName -
      Returns:
      the UI message
    • getPropertyDefault

      public Object getPropertyDefault(String propName)
      Deprecated.
      Get the default value for the given property name.
      Parameters:
      propName -
      Returns:
      the default property value. This MUST be of the type returned by getPropertyClass(propName)
    • getMimetype

      public abstract String getMimetype()
      Deprecated.
      Get the mimetype created by this report builder.
      Returns:
      report mimetype
    • getFileExtension

      public abstract String getFileExtension()
      Deprecated.
      Get the default extension for the report
      Returns:
      default extension
    • getDisplayName

      public abstract String getDisplayName()
      Deprecated.
      Get the display name for the builder.
      Returns:
      display name
    • isBuildCanceled

      public boolean isBuildCanceled()
      Deprecated.
      Has this build been canceled by the user? This method should be called periodically during the build method. If the build has been cancelled, the build method should throw a new ReportBuilderException.
    • buildReport

      public void buildReport(ReportDesign design, Project project, Query q, ResultSet[] resultSets, File file) throws ReportBuilderException
      Deprecated.
      Build the report.
      Parameters:
      design - the report design
      project - the phon project
      resultSets - the selected searches to report on
      file - the output file
      query - the query data
      Throws:
      ReportBuilderException
    • buildReport

      public abstract void buildReport(ReportDesign design, Project project, Query q, ResultSet[] resultSets, OutputStream file) throws ReportBuilderException
      Deprecated.
      Build the report.
      Parameters:
      design - the report design
      project - the phon project
      resultSets - the selected searches to report on
      file - the output file
      query - the query data
      Throws:
      ReportBuilderException