Interface ArtifactValidatorFactory

All Known Implementing Classes:
AgentBundleArtifactValidatorFactory, AgentCreatorBundleValidatorFactory, RequiredArtifactsPresentValidatorFactory

public interface ArtifactValidatorFactory
Factory that produces an ArtifactValidator configured with the supplied ObjectMapper. Built-in factories are discovered via ServiceLoader and their validators registered in the runtime's validator registry.

The factory indirection (rather than a no-argument ArtifactValidator constructor) is required because a validator must parse artifacts with the same configured ObjectMapper the agent loaders use, so validation stays in lockstep with production loading; a ServiceLoader-instantiated no-arg validator would silently fall back to a default mapper.

  • Method Summary

    Modifier and Type
    Method
    Description
    create(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
    Creates a validator bound to the given mapper.
  • Method Details

    • create

      ArtifactValidator create(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
      Creates a validator bound to the given mapper.
      Parameters:
      objectMapper - the configured mapper the produced validator must parse with; must not be null
      Returns:
      the validator instance