# schema_salad.metaschema

## Attributes

`IdxType` |
`S` |
`save_type` |
`strtype` |
`inttype` |
`floattype` |
`booltype` |
`None_type` |
`Any_type` |
`PrimitiveTypeLoader` | Names of salad data types (based on Avro schema declarations).
`AnyLoader` | The Any type validates for any non-null value.
`RecordFieldLoader` |
`RecordSchemaLoader` |
`EnumSchemaLoader` |
`ArraySchemaLoader` |
`MapSchemaLoader` |
`UnionSchemaLoader` |
`JsonldPredicateLoader` |
`SpecializeDefLoader` |
`SaladRecordFieldLoader` |
`SaladRecordSchemaLoader` |
`SaladEnumSchemaLoader` |
`SaladMapSchemaLoader` |
`SaladUnionSchemaLoader` |
`DocumentationLoader` |
`array_of_strtype` |
`union_of_None_type_or_strtype_or_array_of_strtype` |
`uri_strtype_True_False_None_None` |
`union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype` |
`array_of_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype` |
`union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_or_array_of_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype` |
`typedsl_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_or_array_of_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_2` |
`array_of_RecordFieldLoader` |
`union_of_None_type_or_array_of_RecordFieldLoader` |
`idmap_fields_union_of_None_type_or_array_of_RecordFieldLoader` |
`Record_nameLoader` |
`typedsl_Record_nameLoader_2` |
`union_of_None_type_or_strtype` |
`uri_union_of_None_type_or_strtype_True_False_None_None` |
`uri_array_of_strtype_True_False_None_None` |
`Enum_nameLoader` |
`typedsl_Enum_nameLoader_2` |
`uri_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_or_array_of_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_False_True_2_None` |
`Array_nameLoader` |
`typedsl_Array_nameLoader_2` |
`Map_nameLoader` |
`typedsl_Map_nameLoader_2` |
`Union_nameLoader` |
`typedsl_Union_nameLoader_2` |
`union_of_None_type_or_booltype` |
`union_of_None_type_or_inttype` |
`uri_strtype_False_False_1_None` |
`uri_union_of_None_type_or_strtype_False_False_None_None` |
`uri_union_of_None_type_or_strtype_or_array_of_strtype_False_False_None_None` |
`union_of_None_type_or_strtype_or_JsonldPredicateLoader` |
`union_of_None_type_or_Any_type` |
`array_of_SaladRecordFieldLoader` |
`union_of_None_type_or_array_of_SaladRecordFieldLoader` |
`idmap_fields_union_of_None_type_or_array_of_SaladRecordFieldLoader` |
`uri_union_of_None_type_or_strtype_or_array_of_strtype_False_False_1_None` |
`array_of_SpecializeDefLoader` |
`union_of_None_type_or_array_of_SpecializeDefLoader` |
`idmap_specialize_union_of_None_type_or_array_of_SpecializeDefLoader` |
`Documentation_nameLoader` |
`typedsl_Documentation_nameLoader_2` |
`union_of_SaladRecordSchemaLoader_or_SaladEnumSchemaLoader_or_SaladMapSchemaLoader_or_SaladUnionSchemaLoader_or_DocumentationLoader` |
`array_of_union_of_SaladRecordSchemaLoader_or_SaladEnumSchemaLoader_or_SaladMapSchemaLoader_or_SaladUnionSchemaLoader_or_DocumentationLoader` |
`union_of_SaladRecordSchemaLoader_or_SaladEnumSchemaLoader_or_SaladMapSchemaLoader_or_SaladUnionSchemaLoader_or_DocumentationLoader_or_array_of_union_of_SaladRecordSchemaLoader_or_SaladEnumSchemaLoader_or_SaladMapSchemaLoader_or_SaladUnionSchemaLoader_or_DocumentationLoader` |

## Classes

`LoadingOptions` |
`Saveable` | Mark classes than have a save() and fromDoc() function.
`Documented` | Mark classes than have a save() and fromDoc() function.
`RecordField` | A field of a record.
`RecordSchema` | Mark classes than have a save() and fromDoc() function.
`EnumSchema` | Define an enumerated type.
`ArraySchema` | Mark classes than have a save() and fromDoc() function.
`MapSchema` | Mark classes than have a save() and fromDoc() function.
`UnionSchema` | Mark classes than have a save() and fromDoc() function.
`JsonldPredicate` | Attached to a record field to define how the parent record field is handled for
`SpecializeDef` | Mark classes than have a save() and fromDoc() function.
`NamedType` | Mark classes than have a save() and fromDoc() function.
`DocType` | Mark classes than have a save() and fromDoc() function.
`SchemaDefinedType` | Abstract base for schema-defined types.
`SaladRecordField` | A field of a record.
`SaladRecordSchema` | Mark classes than have a save() and fromDoc() function.
`SaladEnumSchema` | Define an enumerated type.
`SaladMapSchema` | Define a map type.
`SaladUnionSchema` | Define a union type.
`Documentation` | A documentation section. This type exists to facilitate self-documenting

## Functions

`load_field`(val, fieldtype, baseuri, loadingOptions[, lc]) | Load field.
`extract_type`(val_type) | Take a type of value, and extracts the value as a string.
`convert_typing`(val_type) | Normalize type names to schema-salad types.
`parse_errors`(error_message) | Parse error messages from several loaders into one error message.
`save`(val[, top, base_url, relative_uris]) |
`save_with_metadata`(val, valLoadingOpts[, top, ...]) | Save and set $namespaces, $schemas, $base and any other metadata fields at the top level.
`expand_url`(url, base_url, loadingOptions[, scoped_id, ...]) |
`file_uri`(path[, split_frag]) | Transform a file path into a URL with file scheme.
`prefix_url`(url, namespaces) | Expand short forms into full URLs using the given namespace dictionary.
`save_relative_uri`(uri, base_url, scoped_id, ref_scope, ...) | Convert any URI to a relative one, obeying the scoping rules.
`shortname`(inputid) | Compute the shortname of a fully qualified identifier.
`parser_info`() |
`load_document`(doc[, baseuri, loadingOptions]) |
`load_document_with_metadata`(doc[, baseuri, ...]) |
`load_document_by_string`(string, uri[, loadingOptions]) |
`load_document_by_yaml`(yaml, uri[, loadingOptions]) | Shortcut to load via a YAML object.

## Module Contents

type schema_salad.metaschema.IdxType = MutableMapping[str, tuple[Any, 'LoadingOptions']]

schema_salad.metaschema.S

class schema_salad.metaschema.LoadingOptions(fetcher=None, namespaces=None, schemas=None, fileuri=None, copyfrom=None, original_doc=None, addl_metadata=None, baseuri=None, idx=None, imports=None, includes=None, no_link_check=None, container=None)
  Parameters:

    - fetcher (schema_salad.fetcher.Fetcher | None)

    - namespaces (dict[str, str] | None)

    - schemas (list[str] | None)

    - fileuri (str | None)

    - copyfrom (LoadingOptions | None)

    - original_doc (Any | None)

    - addl_metadata (dict[str, str] | None)

    - baseuri (str | None)

    - idx (IdxType | None)

    - imports (list[str] | None)

    - includes (list[str] | None)

    - no_link_check (bool | None)

    - container (str | None)

  idx: Final[IdxType]
  fileuri: Final[str | None]
  baseuri: Final[str]
  namespaces: Final[collections.abc.MutableMapping[str, str]]
  schemas: Final[collections.abc.MutableSequence[str]]
  original_doc: Final[Any | None]
  addl_metadata: Final[collections.abc.MutableMapping[str, Any]]
  fetcher: Final[schema_salad.fetcher.Fetcher]
  vocab: Final[dict[str, str]]
  rvocab: Final[dict[str, str]]
  cache: Final[schema_salad.utils.CacheType]
  imports: Final[list[str]]
  includes: Final[list[str]]
  no_link_check: Final[bool | None]
  container: Final[str | None]
  property graph: rdflib.Graph

    Generate a merged rdflib.Graph from all entries in self.schemas.

    Return type:

      rdflib.Graph

class schema_salad.metaschema.Saveable

  Mark classes than have a save() and fromDoc() function.

  classmethod fromDoc(_doc, baseuri, loadingOptions, docRoot=None)
    Abstractmethod:

    Parameters:

      - _doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

    Construct this object from the result of yaml.load().

  abstractmethod save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

schema_salad.metaschema.load_field(val, fieldtype, baseuri, loadingOptions, lc=None)

  Load field.

  Parameters:

    - val (Any | None)

    - fieldtype (_Loader)

    - baseuri (str)

    - loadingOptions (LoadingOptions)

    - lc (Any | None)

  Return type:

    Any

type schema_salad.metaschema.save_type = None | MutableMapping[str, Any] | MutableSequence[Any] | int | float | bool | str

schema_salad.metaschema.extract_type(val_type)

  Take a type of value, and extracts the value as a string.

  Parameters:

    val_type (type[Any])

  Return type:

    str

schema_salad.metaschema.convert_typing(val_type)

  Normalize type names to schema-salad types.

  Parameters:

    val_type (str)

  Return type:

    str

schema_salad.metaschema.parse_errors(error_message)

  Parse error messages from several loaders into one error message.

  Parameters:

    error_message (str)

  Return type:

    tuple[str, str, str]

schema_salad.metaschema.save(val, top=True, base_url='', relative_uris=True)
  Parameters:

    - val (Any)

    - top (bool)

    - base_url (str)

    - relative_uris (bool)

  Return type:

    save_type

schema_salad.metaschema.save_with_metadata(val, valLoadingOpts, top=True, base_url='', relative_uris=True)

  Save and set $namespaces, $schemas, $base and any other metadata fields at the top level.

  Parameters:

    - val (Any)

    - valLoadingOpts (LoadingOptions)

    - top (bool)

    - base_url (str)

    - relative_uris (bool)

  Return type:

    save_type

schema_salad.metaschema.expand_url(url, base_url, loadingOptions, scoped_id=False, vocab_term=False, scoped_ref=None)
  Parameters:

    - url (str)

    - base_url (str)

    - loadingOptions (LoadingOptions)

    - scoped_id (bool)

    - vocab_term (bool)

    - scoped_ref (int | None)

  Return type:

    str

schema_salad.metaschema.file_uri(path, split_frag=False)

  Transform a file path into a URL with file scheme.

  Parameters:

    - path (str)

    - split_frag (bool)

  Return type:

    str

schema_salad.metaschema.prefix_url(url, namespaces)

  Expand short forms into full URLs using the given namespace dictionary.

  Parameters:

    - url (str)

    - namespaces (dict[str, str])

  Return type:

    str

schema_salad.metaschema.save_relative_uri(uri, base_url, scoped_id, ref_scope, relative_uris)

  Convert any URI to a relative one, obeying the scoping rules.

  Parameters:

    - uri (Any)

    - base_url (str)

    - scoped_id (bool)

    - ref_scope (int | None)

    - relative_uris (bool)

  Return type:

    Any

schema_salad.metaschema.shortname(inputid)

  Compute the shortname of a fully qualified identifier.

  See https://w3id.org/cwl/v1.2/SchemaSalad.html#Short_names.

  Parameters:

    inputid (str)

  Return type:

    str

schema_salad.metaschema.parser_info()
  Return type:

    str

class schema_salad.metaschema.Documented

  Bases: `Saveable`

  Mark classes than have a save() and fromDoc() function.

class schema_salad.metaschema.RecordField(name, type_, doc=None, extension_fields=None, loadingOptions=None)

  Bases: `Documented`

  A field of a record.

  Parameters:

    - name (Any)

    - type_ (Any)

    - doc (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  name: str
  doc = None
  type_
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.RecordSchema(type_, fields=None, extension_fields=None, loadingOptions=None)

  Bases: `Saveable`

  Mark classes than have a save() and fromDoc() function.

  Parameters:

    - type_ (Any)

    - fields (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  fields = None
  type_
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.EnumSchema(symbols, type_, name=None, extension_fields=None, loadingOptions=None)

  Bases: `Saveable`

  Define an enumerated type.

  Parameters:

    - symbols (Any)

    - type_ (Any)

    - name (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  name: str
  symbols
  type_
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.ArraySchema(items, type_, extension_fields=None, loadingOptions=None)

  Bases: `Saveable`

  Mark classes than have a save() and fromDoc() function.

  Parameters:

    - items (Any)

    - type_ (Any)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  items
  type_
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.MapSchema(type_, values, extension_fields=None, loadingOptions=None)

  Bases: `Saveable`

  Mark classes than have a save() and fromDoc() function.

  Parameters:

    - type_ (Any)

    - values (Any)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  type_
  values
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.UnionSchema(names, type_, extension_fields=None, loadingOptions=None)

  Bases: `Saveable`

  Mark classes than have a save() and fromDoc() function.

  Parameters:

    - names (Any)

    - type_ (Any)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  names
  type_
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.JsonldPredicate(_id=None, _type=None, _container=None, identity=None, noLinkCheck=None, mapSubject=None, mapPredicate=None, refScope=None, typeDSL=None, secondaryFilesDSL=None, subscope=None, extension_fields=None, loadingOptions=None)

  Bases: `Saveable`

  Attached to a record field to define how the parent record field is handled for URI resolution and JSON-LD context generation.

  Parameters:

    - _id (Any | None)

    - _type (Any | None)

    - _container (Any | None)

    - identity (Any | None)

    - noLinkCheck (Any | None)

    - mapSubject (Any | None)

    - mapPredicate (Any | None)

    - refScope (Any | None)

    - typeDSL (Any | None)

    - secondaryFilesDSL (Any | None)

    - subscope (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  identity = None
  noLinkCheck = None
  mapSubject = None
  mapPredicate = None
  refScope = None
  typeDSL = None
  secondaryFilesDSL = None
  subscope = None
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.SpecializeDef(specializeFrom, specializeTo, extension_fields=None, loadingOptions=None)

  Bases: `Saveable`

  Mark classes than have a save() and fromDoc() function.

  Parameters:

    - specializeFrom (Any)

    - specializeTo (Any)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  specializeFrom
  specializeTo
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.NamedType

  Bases: `Saveable`

  Mark classes than have a save() and fromDoc() function.

class schema_salad.metaschema.DocType

  Bases: `Documented`

  Mark classes than have a save() and fromDoc() function.

class schema_salad.metaschema.SchemaDefinedType

  Bases: `DocType`

  Abstract base for schema-defined types.

class schema_salad.metaschema.SaladRecordField(name, type_, doc=None, jsonldPredicate=None, default=None, extension_fields=None, loadingOptions=None)

  Bases: `RecordField`

  A field of a record.

  Parameters:

    - name (Any)

    - type_ (Any)

    - doc (Any | None)

    - jsonldPredicate (Any | None)

    - default (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  name: str
  doc = None
  type_
  jsonldPredicate = None
  default = None
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.SaladRecordSchema(name, type_, inVocab=None, fields=None, doc=None, docParent=None, docChild=None, docAfter=None, jsonldPredicate=None, documentRoot=None, abstract=None, extends=None, specialize=None, extension_fields=None, loadingOptions=None)

  Bases: `NamedType`, `RecordSchema`, `SchemaDefinedType`

  Mark classes than have a save() and fromDoc() function.

  Parameters:

    - name (Any)

    - type_ (Any)

    - inVocab (Any | None)

    - fields (Any | None)

    - doc (Any | None)

    - docParent (Any | None)

    - docChild (Any | None)

    - docAfter (Any | None)

    - jsonldPredicate (Any | None)

    - documentRoot (Any | None)

    - abstract (Any | None)

    - extends (Any | None)

    - specialize (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  name: str
  inVocab = None
  fields = None
  type_
  doc = None
  docParent = None
  docChild = None
  docAfter = None
  jsonldPredicate = None
  documentRoot = None
  abstract = None
  extends = None
  specialize = None
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.SaladEnumSchema(symbols, type_, name=None, inVocab=None, doc=None, docParent=None, docChild=None, docAfter=None, jsonldPredicate=None, documentRoot=None, extends=None, extension_fields=None, loadingOptions=None)

  Bases: `NamedType`, `EnumSchema`, `SchemaDefinedType`

  Define an enumerated type.

  Parameters:

    - symbols (Any)

    - type_ (Any)

    - name (Any | None)

    - inVocab (Any | None)

    - doc (Any | None)

    - docParent (Any | None)

    - docChild (Any | None)

    - docAfter (Any | None)

    - jsonldPredicate (Any | None)

    - documentRoot (Any | None)

    - extends (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  name: str
  inVocab = None
  symbols
  type_
  doc = None
  docParent = None
  docChild = None
  docAfter = None
  jsonldPredicate = None
  documentRoot = None
  extends = None
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.SaladMapSchema(name, type_, values, inVocab=None, doc=None, docParent=None, docChild=None, docAfter=None, jsonldPredicate=None, documentRoot=None, extension_fields=None, loadingOptions=None)

  Bases: `NamedType`, `MapSchema`, `SchemaDefinedType`

  Define a map type.

  Parameters:

    - name (Any)

    - type_ (Any)

    - values (Any)

    - inVocab (Any | None)

    - doc (Any | None)

    - docParent (Any | None)

    - docChild (Any | None)

    - docAfter (Any | None)

    - jsonldPredicate (Any | None)

    - documentRoot (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  name: str
  inVocab = None
  type_
  values
  doc = None
  docParent = None
  docChild = None
  docAfter = None
  jsonldPredicate = None
  documentRoot = None
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.SaladUnionSchema(name, names, type_, inVocab=None, doc=None, docParent=None, docChild=None, docAfter=None, documentRoot=None, extension_fields=None, loadingOptions=None)

  Bases: `NamedType`, `UnionSchema`, `DocType`

  Define a union type.

  Parameters:

    - name (Any)

    - names (Any)

    - type_ (Any)

    - inVocab (Any | None)

    - doc (Any | None)

    - docParent (Any | None)

    - docChild (Any | None)

    - docAfter (Any | None)

    - documentRoot (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  name: str
  inVocab = None
  names
  type_
  doc = None
  docParent = None
  docChild = None
  docAfter = None
  documentRoot = None
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

class schema_salad.metaschema.Documentation(name, type_, inVocab=None, doc=None, docParent=None, docChild=None, docAfter=None, extension_fields=None, loadingOptions=None)

  Bases: `NamedType`, `DocType`

  A documentation section. This type exists to facilitate self-documenting schemas but has no role in formal validation.

  Parameters:

    - name (Any)

    - type_ (Any)

    - inVocab (Any | None)

    - doc (Any | None)

    - docParent (Any | None)

    - docChild (Any | None)

    - docAfter (Any | None)

    - extension_fields (collections.abc.MutableMapping[str, Any] | None)

    - loadingOptions (LoadingOptions | None)

  name: str
  inVocab = None
  doc = None
  docParent = None
  docChild = None
  docAfter = None
  type_
  __eq__(other)
    Parameters:

      other (Any)

    Return type:

      bool

  __hash__()
    Return type:

      int

  classmethod fromDoc(doc, baseuri, loadingOptions, docRoot=None)

    Construct this object from the result of yaml.load().

    Parameters:

      - doc (Any)

      - baseuri (str)

      - loadingOptions (LoadingOptions)

      - docRoot (str | None)

    Return type:

      Self

  save(top=False, base_url='', relative_uris=True)

    Convert this object to a JSON/YAML friendly dictionary.

    Parameters:

      - top (bool)

      - base_url (str)

      - relative_uris (bool)

    Return type:

      dict[str, Any]

  attrs: ClassVar[collections.abc.Collection[str]]

schema_salad.metaschema.strtype: Final

schema_salad.metaschema.inttype: Final

schema_salad.metaschema.floattype: Final

schema_salad.metaschema.booltype: Final

schema_salad.metaschema.None_type: Final

schema_salad.metaschema.Any_type: Final

schema_salad.metaschema.PrimitiveTypeLoader: Final

  Names of salad data types (based on Avro schema declarations).

  Refer to the [Avro schema declaration documentation](https://avro.apache.org/docs/current/spec.html#schemas) for detailed information.

  null: no value boolean: a binary value int: 32-bit signed integer long: 64-bit signed integer float: single precision (32-bit) IEEE 754 floating-point number double: double precision (64-bit) IEEE 754 floating-point number string: Unicode character sequence

schema_salad.metaschema.AnyLoader: Final

  The Any type validates for any non-null value.

schema_salad.metaschema.RecordFieldLoader: Final

schema_salad.metaschema.RecordSchemaLoader: Final

schema_salad.metaschema.EnumSchemaLoader: Final

schema_salad.metaschema.ArraySchemaLoader: Final

schema_salad.metaschema.MapSchemaLoader: Final

schema_salad.metaschema.UnionSchemaLoader: Final

schema_salad.metaschema.JsonldPredicateLoader: Final

schema_salad.metaschema.SpecializeDefLoader: Final

schema_salad.metaschema.SaladRecordFieldLoader: Final

schema_salad.metaschema.SaladRecordSchemaLoader: Final

schema_salad.metaschema.SaladEnumSchemaLoader: Final

schema_salad.metaschema.SaladMapSchemaLoader: Final

schema_salad.metaschema.SaladUnionSchemaLoader: Final

schema_salad.metaschema.DocumentationLoader: Final

schema_salad.metaschema.array_of_strtype: Final

schema_salad.metaschema.union_of_None_type_or_strtype_or_array_of_strtype: Final

schema_salad.metaschema.uri_strtype_True_False_None_None: Final

schema_salad.metaschema.union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype: Final

schema_salad.metaschema.array_of_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype: Final

schema_salad.metaschema.union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_or_array_of_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype: Final

schema_salad.metaschema.typedsl_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_or_array_of_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_2: Final

schema_salad.metaschema.array_of_RecordFieldLoader: Final

schema_salad.metaschema.union_of_None_type_or_array_of_RecordFieldLoader: Final

schema_salad.metaschema.idmap_fields_union_of_None_type_or_array_of_RecordFieldLoader: Final

schema_salad.metaschema.Record_nameLoader: Final

schema_salad.metaschema.typedsl_Record_nameLoader_2: Final

schema_salad.metaschema.union_of_None_type_or_strtype: Final

schema_salad.metaschema.uri_union_of_None_type_or_strtype_True_False_None_None: Final

schema_salad.metaschema.uri_array_of_strtype_True_False_None_None: Final

schema_salad.metaschema.Enum_nameLoader: Final

schema_salad.metaschema.typedsl_Enum_nameLoader_2: Final

schema_salad.metaschema.uri_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_or_array_of_union_of_PrimitiveTypeLoader_or_RecordSchemaLoader_or_EnumSchemaLoader_or_ArraySchemaLoader_or_MapSchemaLoader_or_UnionSchemaLoader_or_strtype_False_True_2_None: Final

schema_salad.metaschema.Array_nameLoader: Final

schema_salad.metaschema.typedsl_Array_nameLoader_2: Final

schema_salad.metaschema.Map_nameLoader: Final

schema_salad.metaschema.typedsl_Map_nameLoader_2: Final

schema_salad.metaschema.Union_nameLoader: Final

schema_salad.metaschema.typedsl_Union_nameLoader_2: Final

schema_salad.metaschema.union_of_None_type_or_booltype: Final

schema_salad.metaschema.union_of_None_type_or_inttype: Final

schema_salad.metaschema.uri_strtype_False_False_1_None: Final

schema_salad.metaschema.uri_union_of_None_type_or_strtype_False_False_None_None: Final

schema_salad.metaschema.uri_union_of_None_type_or_strtype_or_array_of_strtype_False_False_None_None: Final

schema_salad.metaschema.union_of_None_type_or_strtype_or_JsonldPredicateLoader: Final

schema_salad.metaschema.union_of_None_type_or_Any_type: Final

schema_salad.metaschema.array_of_SaladRecordFieldLoader: Final

schema_salad.metaschema.union_of_None_type_or_array_of_SaladRecordFieldLoader: Final

schema_salad.metaschema.idmap_fields_union_of_None_type_or_array_of_SaladRecordFieldLoader: Final

schema_salad.metaschema.uri_union_of_None_type_or_strtype_or_array_of_strtype_False_False_1_None: Final

schema_salad.metaschema.array_of_SpecializeDefLoader: Final

schema_salad.metaschema.union_of_None_type_or_array_of_SpecializeDefLoader: Final

schema_salad.metaschema.idmap_specialize_union_of_None_type_or_array_of_SpecializeDefLoader: Final

schema_salad.metaschema.Documentation_nameLoader: Final

schema_salad.metaschema.typedsl_Documentation_nameLoader_2: Final

schema_salad.metaschema.union_of_SaladRecordSchemaLoader_or_SaladEnumSchemaLoader_or_SaladMapSchemaLoader_or_SaladUnionSchemaLoader_or_DocumentationLoader: Final

schema_salad.metaschema.array_of_union_of_SaladRecordSchemaLoader_or_SaladEnumSchemaLoader_or_SaladMapSchemaLoader_or_SaladUnionSchemaLoader_or_DocumentationLoader: Final

schema_salad.metaschema.union_of_SaladRecordSchemaLoader_or_SaladEnumSchemaLoader_or_SaladMapSchemaLoader_or_SaladUnionSchemaLoader_or_DocumentationLoader_or_array_of_union_of_SaladRecordSchemaLoader_or_SaladEnumSchemaLoader_or_SaladMapSchemaLoader_or_SaladUnionSchemaLoader_or_DocumentationLoader: Final

schema_salad.metaschema.load_document(doc, baseuri=None, loadingOptions=None)
  Parameters:

    - doc (Any)

    - baseuri (str | None)

    - loadingOptions (LoadingOptions | None)

  Return type:

    Any

schema_salad.metaschema.load_document_with_metadata(doc, baseuri=None, loadingOptions=None, addl_metadata_fields=None)
  Parameters:

    - doc (Any)

    - baseuri (str | None)

    - loadingOptions (LoadingOptions | None)

    - addl_metadata_fields (collections.abc.MutableSequence[str] | None)

  Return type:

    Any

schema_salad.metaschema.load_document_by_string(string, uri, loadingOptions=None)
  Parameters:

    - string (Any)

    - uri (str)

    - loadingOptions (LoadingOptions | None)

  Return type:

    Any

schema_salad.metaschema.load_document_by_yaml(yaml, uri, loadingOptions=None)

  Shortcut to load via a YAML object. yaml: must be from ruamel.yaml.main.YAML.load with preserve_quotes=True

  Parameters:

    - yaml (Any)

    - uri (str)

    - loadingOptions (LoadingOptions | None)

  Return type:

    Any