isCollectionField function

bool isCollectionField(
  1. FieldElement field
)

Implementation

bool isCollectionField(FieldElement field) {
  if (field.type is InterfaceType) {
    ClassElement collectionClass = field.type.element as ClassElement;
    var annotation = getAnnotation(collectionClass, Collection);
    return annotation != null;
  }

  return false;
}