Crates.io | scale-type-resolver |
lib.rs | scale-type-resolver |
version | 0.2.0 |
source | src |
created_at | 2024-02-02 13:00:39.51591 |
updated_at | 2024-04-29 09:38:49.691113 |
description | A low level trait to be generic over how to resolve SCALE type information |
homepage | https://www.parity.io/ |
repository | https://github.com/paritytech/scale-type-resolver |
max_upload_size | |
id | 1124323 |
size | 73,832 |
scale-type-resolver
provides a generic TypeResolver
trait which can be implemented for
any type that is capable of being given a type ID and resolving that into information about
how the type is SCALE encoded. This allows libraries like scale-decode
to be able to decode
SCALE encoded bytes using either a modern type resolver like scale_info::PortableRegistry
,
or using entirely custom type resolvers (which we would need in order decode blocks from pre-V14
metadata).
It's unlikely that you'd depend on this library directly; more likely you'd depend on a library
like scale-decode
which uses and re-exports the TypeResolver
trait itself.
This crate is no_std
by default and doesn't require alloc
except for tests.