betty.serializers.yaml module

The YAML serializer.

final class betty.serializers.yaml.Yaml

Bases: Serializer

The yaml serializer plugin.

Plugin ID

yaml

Class

Yaml

Configuration

not configurable

dump(portable: PortableData, /) str

Serialize data.

load(serialized: str, /) PortableData

Deserialize data.

Raises:

SerializationError – Raised when the dump could not be loaded.

classmethod media_type() MediaType

The media type this serializer can serialize.