Class IguanaSuiteParser

java.lang.Object
org.aksw.iguana.cc.suite.IguanaSuiteParser

public class IguanaSuiteParser extends Object
Creates an IguanaConfig from a given JSON or YAML file, and validates the config using a JSON schema file
  • Constructor Details

    • IguanaSuiteParser

      public IguanaSuiteParser()
  • Method Details

    • parse

      public static Suite parse(Path config, boolean validate) throws IOException
      Parses an IGUANA configuration file and optionally validates it against a JSON schema file, before parsing.
      Parameters:
      config - the path to the configuration file.
      validate - whether to validate the configuration file against the JSON schema file.
      Returns:
      a Suite object containing the parsed configuration.
      Throws:
      IOException - if there is an error during IO.
      IllegalStateException - if the configuration file is invalid.
    • validateConfig

      public static boolean validateConfig(Path config) throws IOException
      Validates an IGUANA configuration file against a JSON schema file.
      Parameters:
      config - the path to the configuration file.
      Returns:
      true if the configuration file is valid, false otherwise.
      Throws:
      IOException - if there is an error during IO.