Class OntModelGeneratorOptions

java.lang.Object
org.brapi.schematools.core.ontmodel.options.OntModelGeneratorOptions
All Implemented Interfaces:
Options, Validatable

public class OntModelGeneratorOptions extends Object implements Options
Options for the GraphQLGenerator.
  • Constructor Details

    • OntModelGeneratorOptions

      public OntModelGeneratorOptions()
  • Method Details

    • load

      public static OntModelGeneratorOptions load(Path optionsFile) throws IOException
      Load the options from an options file in YAML or Json. The options file may have missing (defined) values, in these cases the default values are loaded. See load()
      Parameters:
      optionsFile - The path to the options file in YAML or Json.
      Returns:
      The options loaded from the YAML or Json file.
      Throws:
      IOException - if the options file can not be found or is incorrectly formatted.
    • load

      public static OntModelGeneratorOptions load()
      Load the default options
      Returns:
      The default options
    • load

      public static OntModelGeneratorOptions load(InputStream inputStream) throws IOException
      Load the options from an options input stream in YAML or Json. The options file may have missing (defined) values, in these cases the default values are loaded. See load()
      Parameters:
      inputStream - The input stream in YAML or Json.
      Returns:
      The options loaded from input stream.
      Throws:
      IOException - if the input stream is not valid or the content is incorrectly formatted.
    • validate

      public Validation validate()
      Description copied from interface: Validatable
      Checks if the Validatable object is valid, return a list of errors if it is not valid
      Specified by:
      validate in interface Validatable
      Returns:
      a Validation object than can be used queried to find if the object is valid and any errors if it is not valid