package yocaml

  1. Overview
  2. Docs

Module Metadata.ReadableSource

Parameters

module _ : sig ... end

Signature

t = D.t, provides from_data to convert Data.t into typed values.

include Data.Validation.S
type data := Data.t

Local alias for Yocaml.Data.t.

type t

The OCaml type produced by this validator.

from_data data converts a Yocaml.Data.t into an OCaml value of type t. Returns Ok v on success or Error e on failure.

Provides entity_name, neutral, and validate for metadata validation using the given module D and default fallback V.neutral.

include Required.DATA_READABLE with type t := t
Sourceval entity_name : string

Assigns a name to an entity (a set of metadata).

Describes a neutral element, as a fallback in the absence of metadata. The function can return an error if the request is mandatory.

validate raw_data Validates a data item represented by type Yocaml.Data.t and projects it into a value of type t.