com.hp.lft.report

Class ReportConfigurationFactory



  • public class ReportConfigurationFactory
    extends java.lang.Object
    Interface for creating a configuration that overrides the default LeanFT report behavior or extends its capabilities.
    • Constructor Detail

      • ReportConfigurationFactory

        public ReportConfigurationFactory()
    • Method Detail

      • loadConfigurationFromResources

        public static ModifiableReportConfiguration loadConfigurationFromResources(java.lang.String propertiesFileName)
                                                                            throws java.io.IOException
        Returns a ReportConfiguration with the values defined in the leanft.properties file located in the resources folder. If a value is missing in the specified property file, it is initialized in the returned configuration with the default value.
        Parameters:
        propertiesFileName - the name of the properties file to load (the file must be in the resources folder).
        Returns:
        the ReportConfiguration with the values from the specified properties file.
        Throws:
        java.io.IOException - if the file is not found.
      • loadConfigurationFromExternalPropertiesFile

        public static ModifiableReportConfiguration loadConfigurationFromExternalPropertiesFile(java.lang.String propertiesFilePath)
                                                                                         throws java.io.IOException
        Returns a ReportConfiguration with the values defined in the specified leanft.properties file. If a value is missing in the specified property file, it is initialized in the returned configuration with the default value.
        Parameters:
        propertiesFilePath - the full path of the properties file to load.
        Returns:
        the ReportConfiguration with the values from the specified properties file.
        Throws:
        java.io.IOException - if the file is not found.
      • getReportConfiguration

        public static ModifiableReportConfiguration getReportConfiguration()
                                                                    throws java.io.IOException
        Returns the ModifiableReportConfiguration to use for this project. By default, uses the Report configuration details defined in the project's leanft.properties file.
        However, if an 'lftConfigFile' system variable was specified with a valid leanft.properties file, the Report data from that file is used to initialize the SDKConfiguration.
        Returns:
        the ModifiableReportConfiguration to use for this project
        Throws:
        java.io.IOException