Edit

Share via


RealTimeEndpoint.SendMessage Method

Definition

Overloads

SendMessage(MessageType, RealTimeAddress, ContentType, Byte[])

Synchronously sends a message. The endpoint should be in the Connected state. This method is not recommended for a UI thread.

SendMessage(MessageType, RealTimeAddress, ContentType, Byte[], IEnumerable<SignalingHeader>)

Synchronously sends a message. The session should be in connected state. This method is not recommended for a UI thread.

SendMessage(MessageType, RealTimeAddress, ContentType, Byte[])

Synchronously sends a message. The endpoint should be in the Connected state. This method is not recommended for a UI thread.

public:
 Microsoft::Rtc::Signaling::SipResponseData ^ SendMessage(Microsoft::Rtc::Signaling::MessageType messageType, Microsoft::Rtc::Signaling::RealTimeAddress ^ sessionTarget, System::Net::Mime::ContentType ^ contentType, cli::array <System::Byte> ^ body);
public Microsoft.Rtc.Signaling.SipResponseData SendMessage (Microsoft.Rtc.Signaling.MessageType messageType, Microsoft.Rtc.Signaling.RealTimeAddress sessionTarget, System.Net.Mime.ContentType contentType, byte[] body);
member this.SendMessage : Microsoft.Rtc.Signaling.MessageType * Microsoft.Rtc.Signaling.RealTimeAddress * System.Net.Mime.ContentType * byte[] -> Microsoft.Rtc.Signaling.SipResponseData

Parameters

messageType
MessageType

The message type.

sessionTarget
RealTimeAddress

The URI of the target to send the message.

contentType
ContentType

The content type describing the body. If null text/plain, UTF-8 is assumed.

body
Byte[]

The body for the data.

Returns

The response data.

Exceptions

Thrown when null is passed for a required argument. The argument name for the required argument is part of the exception message.

Thrown when the server or remote participant returns an error. The response code in the exception should give more information about the error.

Thrown when any of the sub operations of this operation failed due to SIP related errors like connection failure, Authentication failure.

Applies to

SendMessage(MessageType, RealTimeAddress, ContentType, Byte[], IEnumerable<SignalingHeader>)

Synchronously sends a message. The session should be in connected state. This method is not recommended for a UI thread.

public:
 Microsoft::Rtc::Signaling::SipResponseData ^ SendMessage(Microsoft::Rtc::Signaling::MessageType messageType, Microsoft::Rtc::Signaling::RealTimeAddress ^ sessionTarget, System::Net::Mime::ContentType ^ contentType, cli::array <System::Byte> ^ body, System::Collections::Generic::IEnumerable<Microsoft::Rtc::Signaling::SignalingHeader ^> ^ signalingHeaders);
public Microsoft.Rtc.Signaling.SipResponseData SendMessage (Microsoft.Rtc.Signaling.MessageType messageType, Microsoft.Rtc.Signaling.RealTimeAddress sessionTarget, System.Net.Mime.ContentType contentType, byte[] body, System.Collections.Generic.IEnumerable<Microsoft.Rtc.Signaling.SignalingHeader> signalingHeaders);
member this.SendMessage : Microsoft.Rtc.Signaling.MessageType * Microsoft.Rtc.Signaling.RealTimeAddress * System.Net.Mime.ContentType * byte[] * seq<Microsoft.Rtc.Signaling.SignalingHeader> -> Microsoft.Rtc.Signaling.SipResponseData

Parameters

messageType
MessageType

The message type.

sessionTarget
RealTimeAddress

The target to send the message.

contentType
ContentType

The content type describing the body. If null text/plain, UTF-8 is assumed.

body
Byte[]

The body for the data.

signalingHeaders
IEnumerable<SignalingHeader>

The headers provided for this message. Can be null.

Returns

The response data.

Exceptions

Thrown when null is passed for a required argument. The argument name for the required argument is part of the exception message.

Thrown when the server or remote participant returns an error. The response code in the exception should give more information about the error.

Thrown when any of the sub operations of this operation failed due to SIP related errors like connection failure, Authentication failure.

Applies to