Class ReportKeyFactory

java.lang.Object
com.inet.report.ReportKeyFactory
All Implemented Interfaces:
Serializable

public class ReportKeyFactory extends Object implements Serializable
This class represents the description / identification of a report. It contains the properties that describes how the engine should render this report (i.e. to HTML or PDF), but also the name and location of the report file.
For more information about the report URL parameters, please refer to the i-net Clear Reports documentation. The instance of the ReportKeyFactory is intended to be serialized and used by a remote service, but it can be useful for a standalone application, too.
Since:
3.0
See Also:
  • Constructor Details

    • ReportKeyFactory

      public ReportKeyFactory(String url)
      Creates a new instance of com.inet.report.ReportKeyFactory. The keys and values must be java.net.URLEncoded, please see the i-net Clear Reports documentation
      The instance of the ReportKeyFactory is intended to be serialized and used by a remote service, but it can be useful for a standalone application, too.
      Example:
      Properties properties = (new ReportKeyFactory("report=file:c:/test.rpt&user=USER&password=PWD")).getProperties();
      Parameters:
      url - The properties that describe / identify a report in the following format: key1=val1&key2=val2.
      Since:
      3.0
      See Also:
    • ReportKeyFactory

      public ReportKeyFactory(Properties props)
      Creates a new instance of com.inet.report.ReportKeyFactory.
      Please see ReportKeyFactory(String) for an example.
      For more information about the report URL properties please refer to the i-net Clear Reports documentation.
      Parameters:
      props - The properties that describe / identify a report.
      Since:
      15.0
      See Also:
  • Method Details

    • getRelevantParams

      public static String getRelevantParams(Properties props)
      Returns a String representation of all relevant parameters from the given properties object. This can be used for the Key generation but not for building a URL.
      Parameters:
      props - The properties that describe / identify the report
      Returns:
      A sorted string representation of all relevant parameters
      Since:
      3.0
      See Also:
    • getRelevantParamsNoSort

      public static String getRelevantParamsNoSort(Properties props)
      Returns a String representation of all relevant parameters from the given properties object. This can be used for building a URL. Because the sorting is undefined this can't be used for a key.
      Parameters:
      props - The properties that describe / identify the report
      Returns:
      An unsorted string representation of all relevant parameters
      Since:
      3.0
      See Also:
    • decodeProps

      public static void decodeProps(Properties props)
      FOR INTERNAL USE ONLY Decode the properties that are send from a client request.
    • getReportId

      public String getReportId()
      Generates an ID which is unique to identify a report. From this ID also the primary key is generated.
      Returns:
      A unique ID to identify a report.
      Since:
      3.0
    • getReportName

      public String getReportName()
      A synonym for getReportId(). Generates an ID which is unique to identify a report. From this ID also the primary key is generated.
      Returns:
      A unique ID to identify a report.
      Since:
      3.0
      See Also:
    • getProperties

      public Properties getProperties()
      Returns the properties object that describes / identifies the report, see the i-net Clear Reports documentation.
      Returns:
      The properties object that describe / identifies the report
      Since:
      3.0
    • getOutputFormat

      public String getOutputFormat()
      Returns the output format of the report that was set via the properties object in the constructor.
      Returns:
      The output format of the report.
      Since:
      3.0
      See Also:
    • getExportFormat

      public String getExportFormat()
      Returns the export format of the report that was set via the properties object in the constructor.
      Returns:
      The export format of the report.
      Since:
      3.0
      See Also:
    • toString

      public String toString()
      Generates a String representation of this object.
      Overrides:
      toString in class Object
      Returns:
      A String representation of this object
      Since:
      3.0