fromString static method

GoogleResponseStatusCode fromString(
  1. String value
)

Implementation

static GoogleResponseStatusCode fromString(String value) => switch (value) {
      'OK' => GoogleResponseStatusCode.ok,
      'ZERO_RESULTS' => GoogleResponseStatusCode.zeroResults,
      'OVER_DAILY_LIMIT' => GoogleResponseStatusCode.overDailyLimit,
      'OVER_QUERY_LIMIT' => GoogleResponseStatusCode.overQueryLimit,
      'REQUEST_DENIED' => GoogleResponseStatusCode.requestDenied,
      'INVALID_REQUEST' => GoogleResponseStatusCode.invalidRequest,
      _ => GoogleResponseStatusCode.unknowError,
    };