Show / Hide Table of Contents

Struct DataChannelOpenMessage

Represents a Data Channel Establishment Protocol (DECP) OPEN message. This message is initially sent using the data channel on the stream used for user messages.

Inherited Members
System.ValueType.Equals(System.Object)
System.ValueType.GetHashCode()
System.ValueType.ToString()
System.Object.Equals(System.Object, System.Object)
System.Object.GetType()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: SIPSorcery.Net
Assembly: SIPSorcery.dll
Syntax
public struct DataChannelOpenMessage
Remarks

See https://tools.ietf.org/html/rfc8832#section-5.1

Fields

| Improve this Doc View Source

ChannelType

This field specifies the type of data channel to be opened. For a list of the formal options DataChannelTypes.

Declaration
public byte ChannelType
Field Value
Type Description
System.Byte
| Improve this Doc View Source

DCEP_OPEN_FIXED_PARAMETERS_LENGTH

Declaration
public const int DCEP_OPEN_FIXED_PARAMETERS_LENGTH = 12
Field Value
Type Description
System.Int32
| Improve this Doc View Source

Label

The name of the data channel. May be an empty string.

Declaration
public string Label
Field Value
Type Description
System.String
| Improve this Doc View Source

MessageType

This field holds the IANA-defined message type for the DATA_CHANNEL_OPEN message.The value of this field is 0x03.

Declaration
public byte MessageType
Field Value
Type Description
System.Byte
| Improve this Doc View Source

Priority

The priority of the data channel.

Declaration
public ushort Priority
Field Value
Type Description
System.UInt16
| Improve this Doc View Source

Protocol

If it is a non-empty string, it specifies a protocol registered in the "WebSocket Subprotocol Name Registry" created in RFC6455.

Declaration
public string Protocol
Field Value
Type Description
System.String
Remarks

The websocket subprotocol names and specification are available at https://tools.ietf.org/html/rfc7118

| Improve this Doc View Source

Reliability

Used to set tolerance for partially reliable data channels.

Declaration
public uint Reliability
Field Value
Type Description
System.UInt32

Methods

| Improve this Doc View Source

GetBytes()

Serialises the DCEP OPEN message to a buffer.

Declaration
public byte[] GetBytes()
Returns
Type Description
System.Byte[]
| Improve this Doc View Source

GetLength()

Gets the length of the serialised DCEP OPEN message.

Declaration
public int GetLength()
Returns
Type Description
System.Int32

The serialised length of this DECEP OPEN message.

| Improve this Doc View Source

Parse(Byte[], Int32)

Parses the an DCEP open message from a buffer.

Declaration
public static DataChannelOpenMessage Parse(byte[] buffer, int posn)
Parameters
Type Name Description
System.Byte[] buffer

The buffer to parse the message from.

System.Int32 posn

The position in the buffer to start parsing from.

Returns
Type Description
DataChannelOpenMessage

A new DCEP open message instance.

| Improve this Doc View Source

WriteTo(Byte[], Int32)

Serialises a Data Channel Establishment Protocol (DECP) OPEN message to a pre-allocated buffer.

Declaration
public ushort WriteTo(byte[] buffer, int posn)
Parameters
Type Name Description
System.Byte[] buffer

The buffer to write the serialised chunk bytes to. It must have the required space already allocated.

System.Int32 posn

The position in the buffer to write to.

Returns
Type Description
System.UInt16

The number of bytes, including padding, written to the buffer.

Extension Methods

JSONWriter.ToJson(Object)
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX