chromium/google_apis/common/api_error_codes.h

// Copyright 2012 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef GOOGLE_APIS_COMMON_API_ERROR_CODES_H_
#define GOOGLE_APIS_COMMON_API_ERROR_CODES_H_

#include <string>

namespace google_apis {

// HTTP errors that can be returned by Google API service.
enum ApiErrorCode {};

// Returns a string representation of ApiErrorCode.
std::string ApiErrorCodeToString(ApiErrorCode error);

// Checks if the error code represents success for drive api.
bool IsSuccessfulDriveApiErrorCode(ApiErrorCode error);

// Checks if the error code represents success for calendar api.
bool IsSuccessfulCalendarApiErrorCode(ApiErrorCode error);

}  // namespace google_apis

#endif  // GOOGLE_APIS_COMMON_API_ERROR_CODES_H_