objectForField method

DartObject? objectForField(
  1. FieldElement field
)

Find annotation for FieldElement if one exists

Implementation

DartObject? objectForField(FieldElement field) {
  final firstOfType = _columnChecker.firstAnnotationOfExact(field);

  if (firstOfType != null) {
    return firstOfType;
  }

  if (field.getter == null) {
    return null;
  }

  return _columnChecker.firstAnnotationOfExact(field.getter!);
}