pub enum VersionedModuleSchema {
    V0(ModuleV0),
    V1(ModuleV1),
    V2(ModuleV2),
}
Expand description

Represents the different schema versions.

The serialization of this type includes the versioning information. The serialization of this is always prefixed with two 255u8 in order to distinguish this versioned schema from the unversioned.

When embedded into a smart contract module, name the custom section concordium-schema.

Variants

V0(ModuleV0)

Version 0 schema, only supported by V0 smart contracts.

V1(ModuleV1)

Version 1 schema, only supported by V1 smart contracts.

V2(ModuleV2)

Version 2 schema, only supported by V1 smart contracts.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Attempt to read a structure from a given source, failing if an error occurs during deserialization or reading. Read more

Attempt to write the structure into the provided writer, failing if only part of the structure could be written. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.