fromElements static method

Iterable<Field> fromElements(
  1. Iterable<FieldElement> elements
)

gets all the fields from the FieldElements

Implementation

static Iterable<Field> fromElements(Iterable<FieldElement> elements) sync* {
  if (elements.isEmpty) {
    return;
  }

  for (final element in elements) {
    // [element.isSynthetic] is true for fields that are
    // declared getters
    // Ignore all static fields
    if (element.isSynthetic || element.isStatic) {
      continue;
    }

    yield Field.fromElement(element);
  }
}