Interface ISerderRegister

Registration interface for Custom serialization and deserialization transformers. Use this interface to register custom logic for classes and objects that require special serialization handling.

IMPORT_PATH: "@daiso-tech/core/serde/contracts"

interface ISerderRegister {
    registerClass<TSerializedClassInstance extends SerializedValueBase>(
        class_: SerializableClass<TSerializedClassInstance>,
        prefix?: OneOrMore<string>,
    ): this;
    registerCustom<
        TCustomDeserialized,
        TCustomSerialized extends SerializedValueBase,
    >(
        transformer: ISerdeTransformer<TCustomDeserialized, TCustomSerialized>,
        prefix?: OneOrMore<string>,
    ): this;
}

Methods