Skip to main content

blockly > serialization > procedures > ProcedureSerializer

serialization.procedures.ProcedureSerializer class

Serializer for saving and loading procedure state.

Signature:

export declare class ProcedureSerializer<ProcedureModel extends IProcedureModel, ParameterModel extends IParameterModel> implements ISerializer 

Implements: ISerializer

Constructors

Constructor

Modifiers

Description

(constructor)(procedureModelClass, parameterModelClass)

Constructs the procedure serializer.

Example usage: new ProcedureSerializer(MyProcedureModelClass, MyParameterModelClass)

Properties

Property

Modifiers

Type

Description

priority

number

Methods

Method

Modifiers

Description

clear(workspace)

Disposes of any procedure models that exist on the workspace.

load(state, workspace)

Deserializes the procedures models defined by the given state into the workspace.

save(workspace)

Serializes the procedure models of the given workspace.