ClassReflectionEntityHandler<O> class

Inheritance

Constructors

ClassReflectionEntityHandler(Type classType, {EntityHandlerProvider? provider, ClassReflection<O>? reflection})

Properties

classType ↔ Type
getter/setter pair
hashCode → int
The hash code for this object.
no setterinherited
jsonReviver ↔ JsonReviver
getter/setter pairinherited
jsonToEncodable ↔ JsonToEncodable?
getter/setter pairinherited
provider → EntityHandlerProvider
The provider of EntityHandler instances for different Types.
finalinherited
reflection → ClassReflection<O>
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
type → Type
The entity Type handled by this instance.
finalinherited
typeInfo → TypeInfo
Returns type as a TypeInfo.
no setterinherited
typeName → String
The entity Type name handled by this instance.
no setteroverride

Methods

allFieldsValids(O o) → bool
inherited
buildFieldsNamesIndexes(List<String> fieldsNames) → Map<String, int>
inherited
buildFieldsNamesLC(List<String> fieldsNames) → List<String>
inherited
buildFieldsNamesSimple(List<String> fieldsNames) → List<String>
inherited
canCastIterable(Iterable itr, Type type) → bool
inherited
canCastIterableNullable(Iterable itr, Type type) → bool
inherited
castIterable(Iterable itr, Type type) → Iterable?
inherited
castIterableNullable(Iterable itr, Type type) → Iterable?
inherited
castList(List list, Type type) → List?
inherited
castListNullable(List list, Type type) → List?
inherited
checkAllFieldsValues(O o) → void
inherited
checkFieldValue<V>(O o, String key, {V? value, bool nullValue = false}) → void
inherited
classifyIterableElements(Iterable<Object?> itr) → IterableClassification
inherited
constructors([O? o]) → Map<String, Map<String, TypeInfo>>?
The constructors of the Entity. If not implemented returns null.
override
copy(O obj) → FutureOr<O?>
Creates a copy of obj.
override
createDefault() → FutureOr<O?>
override
createFromMap(Map<String, dynamic> fields, {EntityProvider? entityProvider, EntityCache? entityCache, EntityHandlerProvider? entityHandlerProvider, EntityRepositoryProvider? entityRepositoryProvider, EntityResolutionRules? resolutionRules, JsonDecoder? jsonDecoder}) → FutureOr<O>
Creates an entity O with fields.
inherited
createFromMapSync(Map<String, dynamic> fields, {EntityProvider? entityProvider, EntityCache? entityCache, EntityHandlerProvider? entityHandlerProvider, EntityRepositoryProvider? entityRepositoryProvider, EntityResolutionRules? resolutionRules, JsonDecoder? jsonDecoder}) → O
Synchronous version of createFromMap.
inherited
decodeJson<T>(String json) → T?
override
decodeObjectJson(String json) → O
inherited
decodeObjectListJson(String json) → List<O>
inherited
encodeJson(dynamic o) → String
inherited
encodeObjectJson(O o) → String
inherited
encodeObjectListJson(Iterable<O> list) → String
inherited
ensureRegistered() → void
inherited
equalsFieldValues(String field, Object? value1, Object? value2, [O? o]) → bool
inherited
equalsValues(Object? value1, Object? value2) → bool
inherited
fieldsEntityAnnotations() → Map<String, List<EntityAnnotation>>
inherited
fieldsNames([O? o]) → List<String>
override
fieldsNamesIndexes([O? o]) → Map<String, int>
inherited
fieldsNamesLC([O? o]) → List<String>
inherited
fieldsNamesSimple([O? o]) → List<String>
inherited
fieldsTypes([O? o]) → Map<String, TypeInfo>
override
fieldsWithEntityReference([O? o]) → Map<String, TypeInfo>
inherited
fieldsWithEntityReferenceList([O? o]) → Map<String, TypeInfo>
inherited
fieldsWithType(bool typeFilter(String fieldName, TypeInfo fieldType), [O? o]) → Map<String, TypeInfo>
inherited
fieldsWithTypeAndAnnotations(bool typeFilter(String fieldName, TypeInfo fieldType, List<EntityAnnotation>? fieldAnnotations), [O? o]) → Map<String, TypeInfo>
inherited
fieldsWithTypeEntity([O? o]) → Map<String, TypeInfo>
inherited
fieldsWithTypeEntityOrReference([O? o]) → Map<String, TypeInfo>
inherited
fieldsWithTypeList([O? o]) → Map<String, TypeInfo>
inherited
fieldsWithTypeListEntity([O? o]) → Map<String, TypeInfo>
inherited
fieldsWithTypeListEntityOrReference([O? o]) → Map<String, TypeInfo>
inherited
fieldToLCKey(String key) → String
inherited
fieldToSimpleKey(String key) → String
inherited
findIdFieldName([O? o]) → String?
getAllFieldsEntityAnnotations([O? o]) → Map<String, List<EntityAnnotation>>?
inherited
getAllFieldsWithEntityAnnotation<T extends EntityAnnotation>([O? o, bool filter(T e)?]) → Map<String, List<T>>
inherited
getContextEntityResolutionRules() → EntityResolutionRules?
The current EntityResolutionRules of the current context.
inherited
getEntityHandler<T>({T? obj, Type? type, String? typeName, EntityHandler? knownEntityHandler}) → EntityHandler<T>?
override
getEntityHandlerByType<T>(Type type, {EntityHandler? knownEntityHandler}) → EntityHandler<T>?
inherited
getEntityRepository<T extends Object>({T? obj, Type? type, String? name, EntityHandlerProvider? entityHandlerProvider, EntityRepositoryProvider? entityRepositoryProvider}) → EntityRepository<T>?
inherited
getEntityRepositoryByType<T extends Object>(Type type, {EntityHandlerProvider? entityHandlerProvider, EntityRepositoryProvider? entityRepositoryProvider}) → EntityRepository<T>?
inherited
getEntityRepositoryByTypeInfo<T extends Object>(TypeInfo typeInfo, {EntityHandlerProvider? entityHandlerProvider, EntityRepositoryProvider? entityRepositoryProvider}) → EntityRepository<T>?
inherited
getField<V>(O o, String key) → V?
override
getFieldAnnotations(O? o, String key) → List<Object>?
getFieldEntityAnnotations(O? o, String key) → List<EntityAnnotation>?
override
getFieldKeyInMap(String field, Map<String, Object?> map, {String? fieldLC, String? fieldSimple, Map<String, String>? mapLC, Map<String, String>? mapSimple}) → String?
Returns a field key from map.
inherited
getFields(O o) → Map<String, dynamic>
override
getFieldsEntityTypes([O? o]) → Map<String, TypeInfo>
inherited
getFieldsEnumTypes([O? o]) → Map<String, TypeInfo>
inherited
getFieldsKeysInMap(List<String> fields, Map<String, Object?> map, {String? fieldLC, String? fieldSimple, Map<String, String>? mapLC, Map<String, String>? mapSimple}) → Map<String, String?>
Returns a Map of field keys from map.
inherited
getFieldsListEntityTypes([O? o]) → Map<String, TypeInfo>
inherited
getFieldsTypes([O? o]) → Map<String, TypeInfo>
inherited
getFieldsValuesFromMap(List<String> fieldsNames, Map<String, Object?> map, {Map<String, int>? fieldsNamesIndexes, List<String>? fieldsNamesLC, List<String>? fieldsNamesSimple, bool includeAbsentFields = false, List<String>? returnMapUsedKeys}) → Map<String, Object?>
Returns a Map with the fields values populated from the provided map.
inherited
getFieldType(O? o, String key, {bool resolveFiledName = false}) → TypeInfo?
override
getFieldValueFromMap(String field, Map<String, Object?> map, {String? fieldLC, String? fieldSimple, Map<String, String>? mapLC, Map<String, String>? mapSimple}) → Object?
Returns a field value from map.
inherited
getID<V>(O o) → V?
inherited
getIDFromMap<V>(Map<String, dynamic>? o) → V?
inherited
getIDs<V>(List<O> os) → List<V?>
inherited
idFieldName([O? o]) → String
override
idType([O? o]) → Type
inherited
inspectObject(O? o) → void
override
instantiateFromMapImpl(Map<String, dynamic> fields, {JsonDecoder? jsonDecoder}) → FutureOr<O?>
override
isEntityInstance(Object? o) → bool
Returns true if o is an entity instance O.
inherited
isValidFieldValue<V>(O o, String key, {V? value, bool nullValue = false}) → bool
inherited
normalizeID(Object? id, {O? obj}) → Object?
inherited
normalizeIDs(Iterable? ids, {O? obj}) → List?
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyKnownEntityRepositoryProvider(EntityRepositoryProvider provider) → void
inherited
reflectionWithObject([O? o]) → ClassReflection<O>
resolveEntityFieldValue(O o, String key, dynamic value, {bool resolveFiledName = false, EntityProvider? entityProvider, EntityCache? entityCache, EntityResolutionRules? resolutionRules}) → FutureOr
inherited
resolveEntityResolutionRules(EntityResolutionRules? resolutionRules) → EntityResolutionRulesResolved
Resolves the resolutionRules to apply. Merges with the current EntityResolutionRules context if needed.
inherited
resolveFieldsNamesAndValues(Map<String, dynamic> fields, {EntityProvider? entityProvider, EntityCache? entityCache, EntityHandlerProvider? entityHandlerProvider, EntityRepositoryProvider? entityRepositoryProvider, List<String>? returnFieldsUsedKeys, EntityResolutionRules? resolutionRules}) → FutureOr<Map<String, Object?>>
inherited
resolveFieldsValues(Map<String, Object?> fields, {O? o, EntityProvider? entityProvider, EntityCache? entityCache, EntityHandlerProvider? entityHandlerProvider, EntityRepositoryProvider? entityRepositoryProvider, EntityResolutionRules? resolutionRules}) → FutureOr<Map<String, Object?>>
inherited
resolveFieldValue(String fieldName, TypeInfo? fieldType, Object? value, {EntityProvider? entityProvider, EntityCache? entityCache, EntityHandlerProvider? entityHandlerProvider, EntityRepositoryProvider? entityRepositoryProvider, EntityResolutionRules? resolutionRules}) → FutureOr<Object?>
inherited
resolveFiledName(List<String> fieldsNames, String fieldName, {Map<String, int>? fieldsNamesIndexes, List<String>? fieldsNamesLC, List<String>? fieldsNamesSimple, bool includeAbsentFields = false, List<String>? returnMapUsedKeys}) → String?
Resolves fieldName to one that matches a fieldsNames element.
inherited
resolveID<V>(Object? value) → V?
inherited
resolveIDFromMap<V>(Map map) → V?
inherited
resolveIDs<V>(Object? value) → List<V>
inherited
resolveValueByType<T>(TypeInfo? type, Object? value, {EntityProvider? entityProvider, EntityCache? entityCache, EntityHandlerProvider? entityHandlerProvider, EntityRepositoryProvider? entityRepositoryProvider, EntityResolutionRules? resolutionRules}) → FutureOr<T?>
inherited
setField<V>(O o, String key, V? value, {bool log = true, EntityCache? entityCache}) → void
override
setFieldsFromMap(O o, Map<String, dynamic> fields, {EntityProvider? entityProvider, EntityCache? entityCache, EntityResolutionRules? resolutionRules}) → FutureOr<O>
inherited
setFieldValueDynamic(O o, String key, dynamic value, {bool resolveFiledName = false, EntityProvider? entityProvider, EntityCache? entityCache, EntityResolutionRules? resolutionRules}) → FutureOr
inherited
setID<V>(O o, V id) → void
inherited
siblingsEntityHandlers() → List<ClassReflectionEntityHandler>
toEntitiesByIdMap(Iterable<O> entities) → Map<dynamic, O>
inherited
toEntitiesMapByIdMap(Iterable<Map<String, dynamic>> entities) → Map<dynamic, Map<String, dynamic>>
inherited
toJson(dynamic o) → dynamic
inherited
toString() → String
A string representation of this object.
override
trySetField<V>(O o, String key, V? value, {EntityCache? entityCache}) → bool
override
validateAllFields(O o) → Map<String, EntityFieldInvalid>?
inherited
validateFieldValue<V>(O o, String key, {V? value, bool nullValue = false}) → EntityFieldInvalid?
inherited

Operators

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