Class GatewayScriptingFunctions

java.lang.Object
com.inductiveautomation.reporting.gateway.scripting.GatewayScriptingFunctions
All Implemented Interfaces:
ReportScriptingFunctions

public class GatewayScriptingFunctions extends Object implements ReportScriptingFunctions
  • Constructor Details

    • GatewayScriptingFunctions

      public GatewayScriptingFunctions(GatewayContext context)
  • Method Details

    • executeReport

      public byte[] executeReport(String reportPath, String fileType, org.python.core.PyDictionary pyParameters, String projectName) throws Exception
      Description copied from interface: ReportScriptingFunctions
      Executes a report and returns the result as a byte array.
      Specified by:
      executeReport in interface ReportScriptingFunctions
      Parameters:
      reportPath - The path to the report.
      fileType - The format of the report (e.g., 'pdf', 'html', 'csv').
      pyParameters - Parameters to pass to the report.
      projectName - The name of the project.
      Returns:
      The executed report as a byte array.
      Throws:
      Exception - if execution fails.
    • executeAndDistribute

      public void executeAndDistribute(String reportPath, org.python.core.PyDictionary pyParameters, String projectName, String action, org.python.core.PyDictionary actionSettings) throws Exception
      Description copied from interface: ReportScriptingFunctions
      Executes a report and distributes it using the specified action.
      Specified by:
      executeAndDistribute in interface ReportScriptingFunctions
      Parameters:
      reportPath - The path to the report.
      pyParameters - Parameters to pass to the report.
      projectName - The name of the project.
      action - The name of the distribution action (e.g., 'email', 'print', 'save').
      actionSettings - Settings for the distribution action.
      Throws:
      Exception - if execution or distribution fails.
    • getReportNames

      public List<ReportScriptingFunctions.ReportNameInfo> getReportNames(String projectName) throws Exception
      Description copied from interface: ReportScriptingFunctions
      Retrieves a list of report names for a project.
      Specified by:
      getReportNames in interface ReportScriptingFunctions
      Parameters:
      projectName - The name of the project.
      Returns:
      A list of report name information.
      Throws:
      Exception - if retrieval fails.