canParse static method

bool canParse(
  1. Object? obj
)

Implementation

static bool canParse(Object? obj) {
  if (obj is! Map<String, dynamic>) {
    return false;
  }
  if (obj['evaluateName'] is! String?) {
    return false;
  }
  if (obj['fullTypeName'] is! String?) {
    return false;
  }
  if ((obj['innerException'] is! List ||
      (obj['innerException']
          .any((item) => !ExceptionDetails.canParse(item))))) {
    return false;
  }
  if (obj['message'] is! String?) {
    return false;
  }
  if (obj['stackTrace'] is! String?) {
    return false;
  }
  if (obj['typeName'] is! String?) {
    return false;
  }
  return true;
}