SDPMessage

The GstSDPMessage helper functions makes it easy to parse and create SDP messages.

class SDPMessage : Boxed {}

Members

Functions

addAttribute
gstsdp.types.SDPResult addAttribute(string key, string value)

Add the attribute with key and value to msg.

addBandwidth
gstsdp.types.SDPResult addBandwidth(string bwtype, uint bandwidth)

Add the specified bandwidth information to msg.

addEmail
gstsdp.types.SDPResult addEmail(string email)

Add email to the list of emails in msg.

addMedia
gstsdp.types.SDPResult addMedia(gstsdp.sdpmedia.SDPMedia media)

Adds media to the array of medias in msg. This function takes ownership of the contents of media so that media will have to be reinitialized with gstsdp.sdpmedia.SDPMedia.init_ before it can be used again.

addPhone
gstsdp.types.SDPResult addPhone(string phone)

Add phone to the list of phones in msg.

addTime
gstsdp.types.SDPResult addTime(string start, string stop, string[] repeat)

Add time information start and stop to msg.

addZone
gstsdp.types.SDPResult addZone(string adjTime, string typedTime)

Add time zone information to msg.

asText
string asText()

Convert the contents of msg to a text string.

attributesLen
uint attributesLen()

Get the number of attributes in msg.

attributesToCaps
gstsdp.types.SDPResult attributesToCaps(gst.caps.Caps caps)

Mapping of attributes of #GstSDPMessage to #GstCaps

bandwidthsLen
uint bandwidthsLen()

Get the number of bandwidth information in msg.

copy
gstsdp.types.SDPResult copy(gstsdp.sdpmessage.SDPMessage copy)

Allocate a new copy of msg and store the result in copy. The value in copy should be release with gst_sdp_message_free function.

dump
gstsdp.types.SDPResult dump()

Dump the parsed contents of msg to stdout.

emailsLen
uint emailsLen()

Get the number of emails in msg.

getAttribute
gstsdp.sdpattribute.SDPAttribute getAttribute(uint idx)

Get the attribute at position idx in msg.

getAttributeVal
string getAttributeVal(string key)

Get the first attribute with key key in msg.

getAttributeValN
string getAttributeValN(string key, uint nth)

Get the nth attribute with key key in msg.

getBandwidth
gstsdp.sdpbandwidth.SDPBandwidth getBandwidth(uint idx)

Get the bandwidth at index idx from msg.

getConnection
gstsdp.sdpconnection.SDPConnection getConnection()

Get the connection of msg.

getEmail
string getEmail(uint idx)

Get the email with number idx from msg.

getInformation
string getInformation()

Get the information in msg.

getKey
gstsdp.sdpkey.SDPKey getKey()

Get the encryption information from msg.

getMedia
gstsdp.sdpmedia.SDPMedia getMedia(uint idx)

Get the media description at index idx in msg.

getOrigin
gstsdp.sdporigin.SDPOrigin getOrigin()

Get the origin of msg.

getPhone
string getPhone(uint idx)

Get the phone with number idx from msg.

getSessionName
string getSessionName()

Get the session name in msg.

getTime
gstsdp.sdptime.SDPTime getTime(uint idx)

Get time information with index idx from msg.

getUri
string getUri()

Get the URI in msg.

getVersion
string getVersion()

Get the version in msg.

getZone
gstsdp.sdpzone.SDPZone getZone(uint idx)

Get time zone information with index idx from msg.

insertAttribute
gstsdp.types.SDPResult insertAttribute(int idx, gstsdp.sdpattribute.SDPAttribute attr)

Insert attribute into the array of attributes in msg at index idx. When -1 is given as idx, the attribute is inserted at the end.

insertBandwidth
gstsdp.types.SDPResult insertBandwidth(int idx, gstsdp.sdpbandwidth.SDPBandwidth bw)

Insert bandwidth parameters into the array of bandwidths in msg at index idx. When -1 is given as idx, the bandwidth is inserted at the end.

insertEmail
gstsdp.types.SDPResult insertEmail(int idx, string email)

Insert email into the array of emails in msg at index idx. When -1 is given as idx, the email is inserted at the end.

insertPhone
gstsdp.types.SDPResult insertPhone(int idx, string phone)

Insert phone into the array of phone numbers in msg at index idx. When -1 is given as idx, the phone is inserted at the end.

insertTime
gstsdp.types.SDPResult insertTime(int idx, gstsdp.sdptime.SDPTime t)

Insert time parameters into the array of times in msg at index idx. When -1 is given as idx, the times are inserted at the end.

insertZone
gstsdp.types.SDPResult insertZone(int idx, gstsdp.sdpzone.SDPZone zone)

Insert zone parameters into the array of zones in msg at index idx. When -1 is given as idx, the zone is inserted at the end.

mediasLen
uint mediasLen()

Get the number of media descriptions in msg.

parseKeymgmt
gstsdp.types.SDPResult parseKeymgmt(gstsdp.mikeymessage.MIKEYMessage mikey)

Creates a new #GstMIKEYMessage after parsing the key-mgmt attribute from a #GstSDPMessage.

phonesLen
uint phonesLen()

Get the number of phones in msg.

removeAttribute
gstsdp.types.SDPResult removeAttribute(uint idx)

Remove the attribute in msg at index idx.

removeBandwidth
gstsdp.types.SDPResult removeBandwidth(uint idx)

Remove the bandwidth information in msg at index idx.

removeEmail
gstsdp.types.SDPResult removeEmail(uint idx)

Remove the email in msg at index idx.

removeMedia
gstsdp.types.SDPResult removeMedia(uint idx)

Remove the media at idx from the array of medias in msg if found.

removePhone
gstsdp.types.SDPResult removePhone(uint idx)

Remove the phone number in msg at index idx.

removeTime
gstsdp.types.SDPResult removeTime(uint idx)

Remove the time information in msg at index idx.

removeZone
gstsdp.types.SDPResult removeZone(uint idx)

Remove the zone information in msg at index idx.

replaceAttribute
gstsdp.types.SDPResult replaceAttribute(uint idx, gstsdp.sdpattribute.SDPAttribute attr)

Replace the attribute in msg at index idx with attr.

replaceBandwidth
gstsdp.types.SDPResult replaceBandwidth(uint idx, gstsdp.sdpbandwidth.SDPBandwidth bw)

Replace the bandwidth information in msg at index idx with bw.

replaceEmail
gstsdp.types.SDPResult replaceEmail(uint idx, string email)

Replace the email in msg at index idx with email.

replacePhone
gstsdp.types.SDPResult replacePhone(uint idx, string phone)

Replace the phone number in msg at index idx with phone.

replaceTime
gstsdp.types.SDPResult replaceTime(uint idx, gstsdp.sdptime.SDPTime t)

Replace the time information in msg at index idx with t.

replaceZone
gstsdp.types.SDPResult replaceZone(uint idx, gstsdp.sdpzone.SDPZone zone)

Replace the zone information in msg at index idx with zone.

setConnection
gstsdp.types.SDPResult setConnection(string nettype, string addrtype, string address, uint ttl, uint addrNumber)

Configure the SDP connection in msg with the given parameters.

setInformation
gstsdp.types.SDPResult setInformation(string information)

Set the information in msg.

setKey
gstsdp.types.SDPResult setKey(string type, string data)

Adds the encryption information to msg.

setOrigin
gstsdp.types.SDPResult setOrigin(string username, string sessId, string sessVersion, string nettype, string addrtype, string addr)

Configure the SDP origin in msg with the given parameters.

setSessionName
gstsdp.types.SDPResult setSessionName(string sessionName)

Set the session name in msg.

setUri
gstsdp.types.SDPResult setUri(string uri)

Set the URI in msg.

setVersion
gstsdp.types.SDPResult setVersion(string version_)

Set the version in msg.

timesLen
uint timesLen()

Get the number of time information entries in msg.

uninit
gstsdp.types.SDPResult uninit()

Free all resources allocated in msg. msg should not be used anymore after this function. This function should be used when msg was allocated on the stack and initialized with gstsdp.sdpmessage.SDPMessage.init_.

zonesLen
uint zonesLen()

Get the number of time zone information entries in msg.

Static functions

asUri
string asUri(string scheme, gstsdp.sdpmessage.SDPMessage msg)

Creates a uri from msg with the given scheme. The uri has the format:

init_
gstsdp.types.SDPResult init_(gstsdp.sdpmessage.SDPMessage msg)

Initialize msg so that its contents are as if it was freshly allocated with gstsdp.sdpmessage.SDPMessage.new_. This function is mostly used to initialize a message allocated on the stack. gstsdp.sdpmessage.SDPMessage.uninit undoes this operation.

newFromText
gstsdp.types.SDPResult newFromText(string text, gstsdp.sdpmessage.SDPMessage msg)

Parse text and create a new SDPMessage from these.

new_
gstsdp.types.SDPResult new_(gstsdp.sdpmessage.SDPMessage msg)

Allocate a new GstSDPMessage and store the result in msg.

parseBuffer
gstsdp.types.SDPResult parseBuffer(ubyte[] data, gstsdp.sdpmessage.SDPMessage msg)

Parse the contents of size bytes pointed to by data and store the result in msg.

parseUri
gstsdp.types.SDPResult parseUri(string uri, gstsdp.sdpmessage.SDPMessage msg)

Parse the null-terminated uri and store the result in msg.

Inherited Members

From Boxed

cInstancePtr
void* cInstancePtr;

Pointer to the C boxed value

getType
GType getType()

Get the GType of this boxed type.

gType
GType gType [@property getter]

Boxed GType property.

self
Boxed self()

Convenience method to return this cast to a type. For use in D with statements.

copy_
void* copy_()

Make a copy of the wrapped C boxed data.

boxedCopy
void* boxedCopy(void* cBoxed)

Copy a C boxed value using g_boxed_copy.

boxedFree
void boxedFree(void* cBoxed)

Free a C boxed value using g_boxed_free.