Class FriendsServiceException
Represents an exception that occurs when communicating with the Unity Friends service.
Namespace: Unity.Services.Friends.Exceptions
Assembly: Unity.Services.Friends.dll
Syntax
public class FriendsServiceException : RequestFailedException
Constructors
FriendsServiceException(HttpStatusCode, string, Exception, FriendsErrorCode)
Creates a FriendsServiceException.
Declaration
public FriendsServiceException(HttpStatusCode statusCode, string message, Exception innerException, FriendsErrorCode errorCode = FriendsErrorCode.Unknown)
Parameters
Type | Name | Description |
---|---|---|
HttpStatusCode | statusCode | The HTTP Status returned by the service. |
string | message | The description of the exception. |
Exception | innerException | The exception raised by the service, if any. |
FriendsErrorCode | errorCode | The error code to be used when raising the issue to the SDK user. |
Properties
ErrorCode
Specific error code
Declaration
public FriendsErrorCode ErrorCode { get; }
Property Value
Type | Description |
---|---|
FriendsErrorCode |
Reason
The reason of the exception.
Declaration
[Obsolete("Reason has been changed to StatusCode.", true)]
public RelationshipErrorCode Reason { get; }
Property Value
Type | Description |
---|---|
RelationshipErrorCode |
StatusCode
The HTTP status code of the exception
Declaration
public HttpStatusCode StatusCode { get; }
Property Value
Type | Description |
---|---|
HttpStatusCode |