Class: SenderLink

SenderLink

Extends

Methods

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

send(msg, optionsopt) → {Promise|null}

Sends the given message, with the given options on this link

Parameters:
Name Type Attributes Description
msg object | string | array

Message to send. Will be encoded using sender link policy's encoder.

options object <optional>

An object of options to attach to the message including: annotations, properties,
and application properties

Properties
Name Type Attributes Description
callback string <optional>

Determines when the send operation should callback. Possible
options are: 'sent', 'settled' and 'none'. For the best performance
choose 'none', which is essentially "send and forget" and notably will
not return a promise.

messageAnnotations object <optional>

Annotations for the message, if any. See AMQP spec for details, and server for specific
annotations that might be relevant (e.g. x-opt-partition-key on EventHub). If node-amqp-encoder'd
map is given, it will be translated to appropriate internal types. Simple maps will be converted
to AMQP Fields type as defined in the spec.

Returns:
Type
Promise | null

Events

attached

Attached event

Inherited From:

detached

Detached event

Inherited From:

errorReceived

Error received event

Parameters:
Name Type Description
error object

the received error

Inherited From: