Home EvaluationOptions Class
EvaluationOptions Class
Cancel

EvaluationOptions Class

Namespace: Json.Schema

Inheritance: EvaluationOptions 🡒 object

Allows configuration of the evaluation process.

Properties

NameTypeSummary
AddAnnotationForUnknownKeywordsboolOutputs an annotation that lists any unknown keywords. Can be useful for catching typos.
AllowReferencesIntoUnknownKeywordsboolGets or sets whether $ref is permitted to navigate into unknown keywords where subschemas aren’t expected. Default is true.
CultureCultureInfoGets or sets the culture for error messages. Overrides Json.Schema.ErrorMessages.Culture.
DefaultEvaluationOptionsThe default settings.
EvaluateAsSpecVersionIndicates which specification version to process as. This will filter the keywords of a schema based on their support.
IgnoredAnnotationsIEnumerable<Type>Gets the set of keyword types from which annotations will be ignored.
OnlyKnownFormatsboolSpecifies whether the format keyword should fail validations for unknown formats. Default is false.
OutputFormatOutputFormatSpecifies the output format.
PreserveDroppedAnnotationsboolIf enabled, annotations that are dropped as a result of a failing subschema will be reported in a droppedAnnotations property in the output.
ProcessCustomKeywordsboolSpecifies whether custom keywords that aren’t defined in vocabularies should be processed. Default is false.
RequireFormatValidationboolSpecifies whether the format keyword should be required to provide validation results. Default is false, which just produces annotations for drafts 2019-09 and prior or follows the behavior set forth by the format-annotation vocabulary requirement in the $vocabulary keyword in a meta-schema declaring draft 2020-12.
SchemaRegistrySchemaRegistryThe local schema registry. If a schema is not found here, it will automatically check the global registry as well.
ValidateAgainstMetaSchemaboolIndicates whether the schema should be validated against its $schema value. this is not typically necessary.

Constructors

EvaluationOptions()

Create a new instance of the Json.Schema.EvaluationOptions class.

Declaration

1
public EvaluationOptions()

Methods

ClearIgnoredAnnotations()

Clears ignored annotations.

Declaration

1
public void ClearIgnoredAnnotations()

CollectAnnotationsFrom()

Restores annotation collection for the specified keyword.

Declaration

1
public void CollectAnnotationsFrom()

From(EvaluationOptions other)

Creates a deep copy of the options.

Declaration

1
public static EvaluationOptions From(EvaluationOptions other)
ParameterTypeDescription
otherEvaluationOptionsThe source options.

Returns

A new options instance with the same settings.

IgnoreAllAnnotations()

Ignores annotations from all keywords.

Declaration

1
public void IgnoreAllAnnotations()

IgnoreAnnotationsFrom()

Ignores annotations from the specified keyword.

Declaration

1
public void IgnoreAnnotationsFrom()
Contents