class Exporter[source]

Bases: abc.ABC

The interface for creating new references during ObjectType.to_bytes.

abstract reference(object, allow_unknown_type=False, force_new=False)[source]

Gets the reference for object if it has already been created and force_new is False, otherwise creates a new one. If allow_unknown_type is False, and no type can be found, no reference will be created.

Return type


class ObjectType[source]

Bases: deephaven.plugin.Plugin

An object type plugin. Useful for serializing custom objects between the server / client.

abstract is_type(object)[source]

Returns true if, and only if, the object is compatible with this object type.

Return type


abstract property name: str

The name of the object type.

Return type


abstract to_bytes(exporter, object)[source]

Serializes object into bytes. Must only be called with a compatible object.

Return type


class Reference(index, type)[source]

Bases: object

A reference.

property index: int

The index, which is defined by the order in which references are created. May be used in the output stream to refer to the reference from the client.

Return type


property type: Optional[str]

The type.

Return type