SerializersFor class

Annotation to trigger code generation of a Serializers instance.

Use like this:

@SerializersFor(const [
  MySerializableClass,
  MyOtherSerializableClass,
])
final Serializers serializers = _$serializers;

The _$serializers value will be generated for you in a part file next to the current source file. It will hold serializers for the types specified plus any types used in their fields, transitively.

Constructors

SerializersFor(List<Type> types)
const

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
types List<Type>
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited