new JsonRpcResponse(message)
Parameters:
Name | Type | Description |
---|---|---|
message |
Object |
Extends
Members
-
isNotification
-
Determinates is current message is notification
- Inherited From:
-
isRequest
-
Determinates is current message is request
- Inherited From:
-
isResponse
-
Determinates is current message is response
- Inherited From:
Methods
-
getError()
-
Gets messeage Error
- Inherited From:
Returns:
- Type
- JsonRpcError
-
getId()
-
Gets messeage id
- Inherited From:
Returns:
- Type
- Number
-
getResult()
-
Gets messeage result
- Inherited From:
Returns:
- Type
- *
-
getVersion()
-
Gets messeage schema version
- Inherited From:
Returns:
- Type
- String
-
setError(error)
-
Sets messeage
Parameters:
Name Type Description error
JsonRpcError | Object - Inherited From:
Returns:
- Type
- JsonRpc
-
setId(id)
-
Sets messeage id
Parameters:
Name Type Description id
Number - Inherited From:
Returns:
- Type
- JsonRpc
-
setResult(result)
-
Sets messeage result
Parameters:
Name Type Description result
* - Inherited From:
Returns:
- Type
- JsonRpc
-
toJSON()
-
- Inherited From:
Returns:
- Type
- Object
-
toString()
-
- Inherited From:
Returns:
- Type
- String