Class CoreV2Validator

java.lang.Object
de.christianmahnke.iiif.fliiifenleger.validation.CoreV2Validator
All Implemented Interfaces:
Validator

@AutoService(Validator.class) public class CoreV2Validator extends Object implements Validator
Core IIIF rules for Image API 2: the fixed @context offers no place for namespaced extension properties, and the embedded profile must start with the Image API 2 compliance level URI.
  • Constructor Details

    • CoreV2Validator

      public CoreV2Validator()
  • Method Details

    • getName

      public String getName()
      Specified by:
      getName in interface Validator
      Returns:
      The unique name of this validator (e.g. "core-context", "c2pa", "hdr").
    • getDescription

      public String getDescription()
      Specified by:
      getDescription in interface Validator
      Returns:
      Short human-readable description of this validator (used by info list-validators).
    • supports

      public boolean supports(ImageInfo.IIIFVersion version)
      Description copied from interface: Validator
      Whether this validator applies to the given IIIF Image API version. Validators returning false are skipped by the facade.
      Specified by:
      supports in interface Validator
      Parameters:
      version - The effective version being validated.
      Returns:
      true if this validator should run.
    • validate

      public ValidationResult validate(tools.jackson.databind.JsonNode node, ImageInfo.IIIFVersion effectiveVersion)
      Description copied from interface: Validator
      Validates one parsed info.json document.
      Specified by:
      validate in interface Validator
      Parameters:
      node - The parsed document; never null and always a JSON object.
      effectiveVersion - The IIIF Image API version being validated against (explicit expectation or auto-detected).
      Returns:
      This validator's slice of the result; detectedVersion may be null (the facade supplies its own detection). Never null.