reflectable/reflectable library
Classes
- Attribute
- decorator used to add meta-data to properties
- ClassAnnotation
-
A
ClassAnnotation
can be used as the base class for type annotations that will get itsapply
method executed by the infrastructure. - ConstructorDescriptor
- Dataclass
- decorator used to mark classes that should emit meta-data
- FieldAnnotation
-
A
FieldAnnotation
can be used as the base class for field annotations that will get itsapply
method executed by the infrastructure. -
FieldDescriptor<
T, V> - MethodAnnotation
-
A
MethodAnnotation
can be used as the base class for method annotations that will get itsapply
method executed by the infrastructure. - MethodDescriptor
- ParameterDescriptor
-
Patch<
T> -
TypeDescriptor<
T> -
Class covering the meta-data of a type.
T
the reflected type - TypePatch
Functions
-
enumeration<
T extends Enum> ({required String name, required List< T> values, List<Object> ? annotations}) → TypeDescriptor<T> -
field<
T, V> (String name, {AbstractType< V, AbstractType< ? type, List<dynamic, AbstractType> >Object> ? annotations, required Getter getter, Setter? setter, Type? elementType, Function? factoryConstructor, bool isFinal = false, bool isNullable = false}) → FieldDescriptor -
method<
T, R> (String name, {List< ParameterDescriptor> ? parameters, bool isAsync = false, bool isStatic = false, dynamic annotations = const [], required Function invoker}) → MethodDescriptor -
nonNullableOf<
T> () → Type -
param<
T> (String name, {bool isNamed = false, bool isRequired = false, bool isNullable = false, List? annotations, dynamic defaultValue}) → ParameterDescriptor -
type<
T> ({required String location, Constructor< T> ? constructor, FromMapConstructor<T> ? fromMapConstructor, FromArrayConstructor<T> ? fromArrayConstructor, List<ParameterDescriptor> ? params, List<FieldDescriptor> ? fields, List<MethodDescriptor> ? methods, TypeDescriptor? superClass, List<Object> ? annotations, bool isAbstract = false}) → TypeDescriptor<T>
Typedefs
-
ApplyFunc<
T> = dynamic Function(T arg) -
Constructor<
T> = Function -
FromArrayConstructor<
T> = T Function(List args) -
FromMapConstructor<
T> = T Function(Map< String, dynamic> args) -
Getter<
T, V> = V Function(T instance) -
Setter<
T, V> = void Function(T instance, V value)