SignalingSession.BeginSendMessage Method

Definition

Overloads

BeginSendMessage(MessageType, ContentType, Byte[], AsyncCallback, Object)

Sends a message. The session should be in the Connected state.

BeginSendMessage(MessageType, ContentType, Byte[], IEnumerable<SignalingHeader>, AsyncCallback, Object)

Send message to participant specified. Participant who is not part of the session is ignored.

BeginSendMessage(MessageType, ContentType, Byte[], AsyncCallback, Object)

Sends a message. The session should be in the Connected state.

public:
 IAsyncResult ^ BeginSendMessage(Microsoft::Rtc::Signaling::MessageType messageType, System::Net::Mime::ContentType ^ contentType, cli::array <System::Byte> ^ body, AsyncCallback ^ userCallback, System::Object ^ state);
public IAsyncResult BeginSendMessage (Microsoft.Rtc.Signaling.MessageType messageType, System.Net.Mime.ContentType contentType, byte[] body, AsyncCallback userCallback, object state);
member this.BeginSendMessage : Microsoft.Rtc.Signaling.MessageType * System.Net.Mime.ContentType * byte[] * AsyncCallback * obj -> IAsyncResult

Parameters

messageType
MessageType

The type of the message body (message or info).

contentType
ContentType

The content type describing the body. Can be null if body is null and if null text/plain, UTF-8 is assumed.

body
Byte[]

The body for the data.

userCallback
AsyncCallback

The method to be called when the asynchronous operation is completed.

state
Object

A user-provided object that distinguishes this particular asynchronous operation from other asynchronous operations.

Returns

IAsyncResult

An IAsyncResult that references the asynchronous operation.

Exceptions

Thrown when the session is in an invalid state to send the message.

Thrown when invalid arguments are passed.

Thrown when arguments are null.

Applies to

BeginSendMessage(MessageType, ContentType, Byte[], IEnumerable<SignalingHeader>, AsyncCallback, Object)

Send message to participant specified. Participant who is not part of the session is ignored.

public:
 IAsyncResult ^ BeginSendMessage(Microsoft::Rtc::Signaling::MessageType messageType, System::Net::Mime::ContentType ^ contentType, cli::array <System::Byte> ^ body, System::Collections::Generic::IEnumerable<Microsoft::Rtc::Signaling::SignalingHeader ^> ^ signalingHeaders, AsyncCallback ^ userCallback, System::Object ^ state);
public IAsyncResult BeginSendMessage (Microsoft.Rtc.Signaling.MessageType messageType, System.Net.Mime.ContentType contentType, byte[] body, System.Collections.Generic.IEnumerable<Microsoft.Rtc.Signaling.SignalingHeader> signalingHeaders, AsyncCallback userCallback, object state);
member this.BeginSendMessage : Microsoft.Rtc.Signaling.MessageType * System.Net.Mime.ContentType * byte[] * seq<Microsoft.Rtc.Signaling.SignalingHeader> * AsyncCallback * obj -> IAsyncResult

Parameters

messageType
MessageType

Type of the body of the message

contentType
ContentType

Content type describing the body. Can be null if body is null and if null text/plain, UTF-8 is assumed.

body
Byte[]

The body for the data. Can be null.

signalingHeaders
IEnumerable<SignalingHeader>

Headers provided for this invite. Can be null.

userCallback
AsyncCallback

The method to be called when the asynchronous operation is completed.

state
Object

A user-provided object that distinguishes this particular asynchronous operation from other asynchronous operations.

Returns

IAsyncResult

An IAsyncResult that references the asynchronous operation.

Exceptions

Thrown when a body is specified without a content type with media type. MessageType is not Message or Info.

Thrown when called in an invalid state.

Applies to