Class CheckerFixerFactory

java.lang.Object
chemaxon.structurechecker.factory.CheckerFixerFactory

@PublicApi public final class CheckerFixerFactory extends Object
Factory for structure checkers and structure fixers.
Since:
5.12
  • Field Details

    • EXTERNAL_CHECKER_CONFIGURATION_PATH_PROPERTY_KEY

      public static final String EXTERNAL_CHECKER_CONFIGURATION_PATH_PROPERTY_KEY
      Java System Property key to globally override default configuration path. Accepts absolute file path or URL in String format.
      Since:
      6.1.1
      See Also:
    • DEFAULT

      public static final String DEFAULT
      default factory id
      See Also:
    • USER_DEFINED_CHECKERCONFIG_XML

      public static final String USER_DEFINED_CHECKERCONFIG_XML
      Users checker configuration file name
      See Also:
    • DEFAULT_CONFIGURATION_PATH

      public static final String DEFAULT_CONFIGURATION_PATH
      Chemaxon's default checker configuration path
      See Also:
  • Method Details

    • getInstance

      public static CheckerFixerFactory getInstance()
      Creates a CheckerFixerFactory based on the DEFAULT_CONFIGURATION_PATH and the user defined checkers/fixers located at the default user
      Returns:
      the default checker fixer factory
    • reloadDefaultInstance

      public static void reloadDefaultInstance()
      Reloads the content of the default factory instance
    • getAvailableCheckers

      public List<StructureChecker> getAvailableCheckers()
      This method returns all StructureChecker instances available by the current configuration
      Returns:
      all StructureChecker instances available by the current configuration
    • getAvailableFixers

      public List<StructureFixer> getAvailableFixers()
      This method returns all StructureFixer instances available by the current configuration
      Returns:
      all StructureFixer instances available by the current configuration
    • createChecker

      public StructureChecker createChecker(String checkerId, Map<String,String> params)
      This method creates a requested (type represented in checkerId) StructureChecker instance with the give parameters
      Parameters:
      checkerId - the Id of the checker
      params - is a Map contains String pairs representing a property bag should be passed to the checker instance
      Returns:
      a well configured StructureChecker instance
    • createFixer

      public StructureFixer createFixer(String fixerId)
      This method creates a StructureFixer instance identified by fixerId parameters
      Parameters:
      fixerId - a String object which is the unique id of the StructureFixer class
      Returns:
      a StructureFixer instance if there is any identified by the fixerName parameter, null otherwise
    • writeConfiguration

      public void writeConfiguration(OutputStream outputstream)
      Writes the factory configuration to the output stream
      Parameters:
      outputstream - the target output stream