Extends
Methods
accept(message)
Settle a message (or array of messages) with an Accepted delivery outcome
Parameters:
Name | Type | Description |
---|---|---|
message |
string | array | message, or array of messages to settle |
addCredits(credits, flowOptionsopt)
Add credits to this link
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
credits |
number | number of credits to add |
|
flowOptions |
object |
<optional> |
additional options to include in flow frame |
detach(optionsopt) → {Promise}
Detach the link from the session
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
options |
object |
<optional> |
detach frame options |
- Inherited From:
Returns:
- Type
- Promise
modify(message, optionsopt)
Settle a message (or array of messages) with a Modified delivery outcome
Parameters:
Name | Type | Attributes | Description | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
message |
string | array | message, or array of messages to settle |
|||||||||||||||||
options |
object |
<optional> |
options used for a Modified outcome Properties
|
reject(message, erroropt)
Settle a message (or array of messages) with a Rejected delivery outcome
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
message |
string | array | message, or array of messages to settle |
|
error |
string |
<optional> |
error that caused the message to be rejected |
release(message)
Settle a message (or array of messages) with a Released delivery outcome
Parameters:
Name | Type | Description |
---|---|---|
message |
string | array | message, or array of messages to settle |
settle(message, stateopt)
Settle a message (or array of messages) with a given delivery state
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
message |
string | array | message, or array of messages to settle |
|
state |
object |
<optional> |
outcome of message delivery |
Events
attached
Attached event
- Inherited From:
creditChange
Credit change event
detached
Detached event
- Inherited From:
errorReceived
Error received event
Parameters:
Name | Type | Description |
---|---|---|
error |
object | the received error |
- Inherited From:
message
Message received event. Message payload given as argument.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
message |
object | the received message |
|
transferFrame |
object |
<optional> |
the transfer frame the message was extracted from |