Show / Hide Table of Contents

Class ServiceException

A Service Exception.

Inheritance
System.Object
System.Exception
ServiceException
Inherited Members
System.Exception.GetBaseException()
System.Exception.Data
System.Exception.HelpLink
System.Exception.HResult
System.Exception.InnerException
System.Exception.Message
System.Exception.Source
System.Exception.StackTrace
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: Microsoft.Graph.CoreSDK.Exceptions
Assembly: Microsoft.Graph.CoreSDK.dll
Syntax
public class ServiceException : Exception

Constructors

View Source

ServiceException(Error, Exception)

Initializes a new instance of the ServiceException class.

Declaration
public ServiceException(Error error = null, Exception innerException = null)
Parameters
Type Name Description
Error error

The error.

System.Exception innerException

The inner exception.

Properties

View Source

Error

Gets the error.

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

The error.

View Source

ResponseHeaders

Gets or sets the response headers.

Declaration
public HttpResponseHeaders ResponseHeaders { get; set; }
Property Value
Type Description
System.Net.Http.Headers.HttpResponseHeaders

The response headers.

View Source

StatusCode

Gets or sets the status code.

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

The status code.

Methods

View Source

IsMatch(String)

Determines whether the specified error code is a match.

Declaration
public bool IsMatch(string errorCode)
Parameters
Type Name Description
System.String errorCode

The error code.

Returns
Type Description
System.Boolean

true if the specified error code is a match; otherwise, false.

Exceptions
Type Condition
System.ArgumentException

errorCode cannot be null or empty - errorCode

View Source

ToString()

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

See Also

System.Exception
  • View Source
Back to top Generated by DocFX