methodInvocationFromMap method
MethodInvocation<O>
methodInvocationFromMap(
- Map<
String, dynamic> map, { - FieldValueResolver? reviver,
- FieldNameResolver? nameResolver,
- bool jsonName = false,
Creates a MethodInvocation using map
entries as parameters.
Implementation
MethodInvocation<O> methodInvocationFromMap(Map<String, dynamic> map,
{FieldValueResolver? reviver,
FieldNameResolver? nameResolver,
bool jsonName = false}) {
if (jsonName) {
final fieldsAliases = classReflection.fieldsJsonNameAliases;
final fieldsAliasesReverse = classReflection.fieldsJsonNameAliasesReverse;
return methodInvocation((p, i) => _parameterResolverJsonAlias(p, i, map,
nameResolver, reviver, fieldsAliases, fieldsAliasesReverse));
} else {
return methodInvocation(
(p, i) => _parameterResolver(p, i, map, nameResolver, reviver));
}
}