getMember method
dynamic
getMember(
- dynamic obj,
- String member, {
- bool nullable = false,
})
inherited
Implementation
@protected
dynamic getMember(dynamic obj, String member, {bool nullable = false}) {
var found = false;
dynamic result;
for (var a in memberAccessors) {
if (a.canHandle(obj, member)) {
result = a.getMember(obj, member);
found = true;
break;
}
}
if (!found) {
try {
result = lookupStandardMembers(obj, member);
if (result != null) {
found = true;
}
} catch (e) {
// no-op
}
}
if (!found && !nullable) {
throw ExpressionEvaluatorException.memberAccessNotSupported(
obj.runtimeType,
member,
);
}
return result;
}