fromName static method

Unit fromName(
  1. String name
)

Implementation

static Unit fromName(String name) {
  int var2 = _values.length;

  for (int var3 = 0; var3 < var2; ++var3) {
    Unit d = _values[var3];
    if (d._name == name) {
      return d;
    }
  }

  return Mm;
}