generic_reader library

Library providing a customizable generic reader aimed at creating runtime constant objects from a static representation of a compile-time constant expression such as ConstantReader or DartObject.

Classes

InvalidTypeArgument
This type of error is thrown if an invalid type argument is provided for a generic type.
UnknownType
A type is not registered and cannot be registered with GenericReader.

Extensions

GenericReader on ConstantReader
Adds the following methods to ConstantReader: get<T>(), getList<T>(), getSet<T>(), getMap<K, V>(), holdsA<T>().
TypeMethods on ConstantReader
Extension adding the type methods to ConstantReader.

Typedefs

Decoder<T> = T Function(ConstantReader constantReader)
Typedef of a function with return type T and an input argument of type ConstantReader.