Package | org.igniterealtime.xiff.data.si |
Class | public class StreamInitiationExtension |
Inheritance | StreamInitiationExtension ![]() ![]() ![]() ![]() |
Implements | IExtension |
To be used with XEP-0096: SI File Transfer
The si element is the root element for this protocol. It is an identifiable container for all the information necessary for negotiation and signalling. It contains attributes for the identifier, intended MIME-type, and profile. The contents convey stream-negotation and profile information.
When the Sender first negotiates a Stream Initiation, all of the attributes SHOULD be present, and the id" and "profile" MUST be present. The contents MUST contain one profile, in the namespace declared in the "profile" attribute, and the feature negotiation for the stream. The feature negotiation MUST contain at least one option and use the field var "stream-method".
When the Receiver accepts a Stream Initiation, the si element SHOULD NOT possess any attributes. The selected stream MUST be in the feature negotiation for the stream. There MUST only be one selected stream.
See also
Property | Defined By | ||
---|---|---|---|
id : String
The "id" attribute is an opaque identifier. | StreamInitiationExtension | ||
mimeType : String
The "mime-type" attribute identifies the MIME-type for
the data across the stream. | StreamInitiationExtension | ||
profile : String
The "profile" attribute defines the SI profile in use. | StreamInitiationExtension | ||
![]() | xml : XML [override]
Override in order to take care of setting the Namespace and
checking for containing extensions. | Extension |
Method | Defined By | ||
---|---|---|---|
StreamInitiationExtension(parent:XML = null) | StreamInitiationExtension | ||
![]() |
Add extension to the list of the given namespace and insert to the XML element as a child. | ExtensionContainer | |
![]() | getAllExtensions():Array | ExtensionContainer | |
![]() | getAllExtensionsByNS(nameSpace:String):Array | ExtensionContainer | |
![]() | getAttribute(name:String):String
Convinience method for getting element value from the XML. | XMLStanza | |
![]() | getChildAttribute(elem:String, name:String):String
Convinience method for getting child element attribute value from the XML. | XMLStanza | |
![]() | getChildField(elem:String, name:String):String
Convinience method for getting child element value from the XML. | XMLStanza | |
getElementName():String | StreamInitiationExtension | ||
![]() | getExtension(elementName:String):IExtension
Get the extension having the given element name. | ExtensionContainer | |
![]() | getField(name:String):String
Convinience method for getting element value from the XML. | XMLStanza | |
getNS():String | StreamInitiationExtension | ||
![]() | remove():void
Removes the extension from its parent. | Extension | |
![]() | removeAllExtensions(nameSpace:String):void | ExtensionContainer | |
![]() | removeExtension(extension:IExtension):Boolean | ExtensionContainer | |
![]() | removeFields(name:String):void
Helper method for removing all child elements that have the given name. | XMLStanza | |
![]() | setAttribute(name:String, value:String):void
Convinience method for setting a value to a element in the XML. | XMLStanza | |
![]() | setChildAttribute(elem:String, name:String, value:String):void
Convinience method for setting an attribute for a child element of the XML. | XMLStanza | |
![]() | setChildField(elem:String, name:String, value:String):void
Convinience method for setting a value for a child element of the XML. | XMLStanza | |
![]() | setField(name:String, value:String):void
Convinience method for setting a value to a element in the XML. | XMLStanza | |
![]() | toString():String
Converts the base stanza XML to a string. | XMLStanza |
Constant | Defined By | ||
---|---|---|---|
![]() | DEFAULT_NS : Namespace [static]
Default XML namespace. | XMLStanza | |
ELEMENT_NAME : String = si [static] | StreamInitiationExtension | ||
![]() | FLASH_NS : Namespace [static]
| XMLStanza | |
NS : String = http://jabber.org/protocol/si [static] | StreamInitiationExtension | ||
PROFILE_PREFIX : String = http://jabber.org/protocol/si/profile/ [static]
The SUGGESTED format for profile namespaces is, followed by the profile name. | StreamInitiationExtension | ||
![]() | STREAM_NS : Namespace [static]
| XMLStanza |
id | property |
id:String
The "id" attribute is an opaque identifier.
This attribute MUST be present on type='set', and MUST be a valid string. This SHOULD NOT be sent back on type='result', since the iq "id" attribute provides the only context needed. This value is generated by the Sender, and the same value MUST be used throughout a session when talking to the Receiver.
public function get id():String
public function set id(value:String):void
mimeType | property |
mimeType:String
The "mime-type" attribute identifies the MIME-type for the data across the stream.
This attribute MUST be a valid MIME-type as registered with the Internet Assigned Numbers Authority (IANA).
During negotiation, this attribute SHOULD be present, and is otherwise not required. If not included during negotiation, its value is assumed to be "application/octet-stream".
public function get mimeType():String
public function set mimeType(value:String):void
See also
profile | property |
profile:String
The "profile" attribute defines the SI profile in use.
This value MUST be present during negotiation, and is the namespace of the profile to use.
TODO: Check validity against PROFILE_PREFIX.
public function get profile():String
public function set profile(value:String):void
StreamInitiationExtension | () | Constructor |
public function StreamInitiationExtension(parent:XML = null)
Parameters
parent:XML (default = null )
|
getElementName | () | method |
public function getElementName():String
ReturnsString |
getNS | () | method |
public function getNS():String
ReturnsString |
ELEMENT_NAME | Constant |
public static const ELEMENT_NAME:String = si
NS | Constant |
public static const NS:String = http://jabber.org/protocol/si
PROFILE_PREFIX | Constant |
public static const PROFILE_PREFIX:String = http://jabber.org/protocol/si/profile/
The SUGGESTED format for profile namespaces is, followed by the profile name.
See also