fromString static method

MetricType fromString(
  1. String string
)

Implementation

static MetricType fromString(String string) {
  var returnType = counter;
  if (string == "Gauge") {
    returnType = gauge;
  }

  return returnType;
}