Show / Hide Table of Contents

Class GoogleApiException

Represents an exception thrown by an API Service.

Inheritance
System.Object
GoogleApiException
Namespace: Google
Assembly: Google.Apis.Core.dll
Syntax
public class GoogleApiException : Exception

Constructors

GoogleApiException(String, String)

Creates an API Service exception.

Declaration
public GoogleApiException(string serviceName, string message)
Parameters
Type Name Description
System.String serviceName
System.String message

GoogleApiException(String, String, Exception)

Creates an API Service exception.

Declaration
public GoogleApiException(string serviceName, string message, Exception inner)
Parameters
Type Name Description
System.String serviceName
System.String message
System.Exception inner

Properties

Error

The Error which was returned from the server, or null if unavailable.

Declaration
public RequestError Error { get; set; }
Property Value
Type Description
RequestError

HttpStatusCode

The HTTP status code which was returned along with this error, or 0 if unavailable.

Declaration
public HttpStatusCode HttpStatusCode { get; set; }
Property Value
Type Description
System.Net.HttpStatusCode

ServiceName

Gets the service name which related to this exception.

Declaration
public string ServiceName { get; }
Property Value
Type Description
System.String

Methods

ToString()

Returns a summary of this exception.

Declaration
public override string ToString()
Returns
Type Description
System.String

A summary of this exception.

Extension Methods

Utilities.ThrowIfNull<T>(T, String)
Back to top