AdapterGenerator class

Given a model, outputs generated code to use as a Brick adapter.

Constructors

AdapterGenerator({required String superAdapterName, required String className, required List<SerdesGenerator<FieldSerializable, Model>> generators})
const

Properties

allAdapterMethods String
Generated adapter methods
no setter
allInstanceFieldsAndMethods String
Any special instance fields the serdes generator needs to forward to the adapter
no setter
className String
The adapted class
final
generators List<SerdesGenerator<FieldSerializable, Model>>
The generated output for serializing/deserializing to JSON and SQLite
final
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
serializerFunctions String
The functions that serialize or deserialize, ultimately used by the adapter method
no setter
superAdapterName String
The name of the adapter this instance will extend. For example, OfflineFirst. Does not end in Adapter.
final

Methods

generate() String
Complete adapter code, including imports and serialization/deserialization
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