Agora Java API Reference for Android

Public Member Functions | List of all members
io.agora.rtm.ErrorInfo Class Reference

## Public Member Functions
| ErrorInfo (RtmErrorCode errorCode)
| ErrorInfo (RtmErrorCode errorCode, String reason)
| ErrorInfo (RtmErrorCode errorCode, String reason, String operation)
RtmErrorCode | getErrorCode ()
String | getErrorReason ()
String | getOperation ()
String | toString ()

## Detailed Description

The warning or error code and description.

## Constructor & Destructor Documentation

## ◆ ErrorInfo() [1/3]

io.agora.rtm.ErrorInfo.ErrorInfo | ( | RtmErrorCode | errorCode | ) |

Constructs a new instance of RtmErrorCode with the specified errorCode.

Parameters

  errorCode | The error code of ErrorInfo(which is saved for later retrieval by the getErrorCode() method)

## ◆ ErrorInfo() [2/3]

io.agora.rtm.ErrorInfo.ErrorInfo | ( | RtmErrorCode | errorCode,
|  | String | reason
| ) |  |

Constructs a new instance of RtmErrorCode with the specified errorCode and specified reason detail.

Parameters

  errorCode | The error code of ErrorInfo (which is saved for later retrieval by the getErrorCode() method)
  reason | A string describing the reason for operation operation failure(which is saved for later retrieval by the getErrorReason() method)

## ◆ ErrorInfo() [3/3]

io.agora.rtm.ErrorInfo.ErrorInfo | ( | RtmErrorCode | errorCode,
|  | String | reason,
|  | String | operation
| ) |  |

Constructs a new instance of RtmErrorCode with the specified errorCode, specified reason detail and specified operation.

Parameters

  errorCode | The error code of ErrorInfo (which is saved for later retrieval by the getErrorCode() method)
  reason | A string describing the reason for operation failure(which is saved for later retrieval by the getErrorReason() method)
  operation | Current operation(which is saved for later retrieval by the getOperation() method)

## Member Function Documentation

## ◆ getErrorCode()

RtmErrorCode io.agora.rtm.ErrorInfo.getErrorCode | ( |  | ) |

Retrieves the warning or error code.

Returns
  The warning or error code. See RtmConstants.RtmErrorCode for a list of warning or error codes.

## ◆ getErrorReason()

String io.agora.rtm.ErrorInfo.getErrorReason | ( |  | ) |

Retrieves the warning or error reason.

Returns
  The warning or error reason. See RtmConstants.RtmErrorCode for a list of warning or error codes.

## ◆ getOperation()

String io.agora.rtm.ErrorInfo.getOperation | ( |  | ) |

Retrieves current operation.

Returns
  current operation.