Class ExecutionConfig


  • public class ExecutionConfig
    extends Object
    Configuration per execution.
    • Constructor Detail

      • ExecutionConfig

        public ExecutionConfig()
    • Method Detail

      • getLocale

        public Locale getLocale()
      • setLocale

        public void setLocale​(Locale locale)
      • getAnnotationAllowedPredicate

        public Predicate<String> getAnnotationAllowedPredicate()
        Gets the predicate to determine if annotation collection is allowed for a particular keyword.

        The default value is to allow annotation collection.

        Setting this to return false improves performance but keywords such as unevaluatedItems and unevaluatedProperties will fail to evaluate properly.

        This will also affect reporting if annotations need to be in the output format.

        unevaluatedProperties depends on properties, patternProperties and additionalProperties.

        unevaluatedItems depends on items/prefixItems, additionalItems/items and contains.

        Returns:
        the predicate to determine if annotation collection is allowed for the keyword
      • setAnnotationAllowedPredicate

        public void setAnnotationAllowedPredicate​(Predicate<String> annotationAllowedPredicate)
        Predicate to determine if annotation collection is allowed for a particular keyword.

        The default value is to allow annotation collection.

        Setting this to return false improves performance but keywords such as unevaluatedItems and unevaluatedProperties will fail to evaluate properly.

        This will also affect reporting if annotations need to be in the output format.

        unevaluatedProperties depends on properties, patternProperties and additionalProperties.

        unevaluatedItems depends on items/prefixItems, additionalItems/items and contains.

        Parameters:
        annotationAllowedPredicate - the predicate accepting the keyword
      • getFormatAssertionsEnabled

        public Boolean getFormatAssertionsEnabled()
        Gets the format assertion enabled flag.

        This defaults to null meaning that it will follow the defaults of the specification.

        Since draft 2019-09 this will default to false unless enabled by using the $vocabulary keyword.

        Returns:
        the format assertions enabled flag
      • setFormatAssertionsEnabled

        public void setFormatAssertionsEnabled​(Boolean formatAssertionsEnabled)
        Sets the format assertion enabled flag.
        Parameters:
        formatAssertionsEnabled - the format assertions enabled flag