Skip to main content

SerMode

No overview available.

Attributes

AttributeTypeDescription
Python[SerMode](sermode.md?sid=serializers_extra_sermode)Specifies that the serialization mode is tailored for Python-specific data structures and types.
Json[SerMode](sermode.md?sid=serializers_extra_sermode)Specifies that the serialization mode follows standard JSON formatting conventions.
OtherStringSpecifies a custom serialization mode identified by a unique string label.

Methods


Python()

def Python() - > [SerMode](sermode.md?sid=serializers_extra_sermode)

Represents a serialization mode specifically for Python-native objects and data structures.

Returns

TypeDescription
[SerMode](sermode.md?sid=serializers_extra_sermode)An instance of the SerMode enum representing Python serialization.

Json()

def Json() - > [SerMode](sermode.md?sid=serializers_extra_sermode)

Represents a serialization mode for standard JSON format, typically used for web-based data exchange.

Returns

TypeDescription
[SerMode](sermode.md?sid=serializers_extra_sermode)An instance of the SerMode enum representing JSON serialization.

Other()

def Other(
mode: string
) - > [SerMode](sermode.md?sid=serializers_extra_sermode)

Represents a custom serialization mode defined by a specific string identifier.

Parameters

NameTypeDescription
modestringThe unique string identifier for the custom serialization format.

Returns

TypeDescription
[SerMode](sermode.md?sid=serializers_extra_sermode)An instance of the SerMode enum representing a custom serialization format.