Class: Jabber::Bytestreams::IqSi
- Inherits:
-
XMPPElement
- Object
- REXML::Element
- XMPPElement
- Jabber::Bytestreams::IqSi
- Defined in:
- lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb
Overview
Iq child ‘si’ for Stream-Initiation
Instance Method Summary collapse
-
#feature ⇒ Object
- <feature/> child result
-
[IqFeature].
-
#file ⇒ Object
- <file/> child result
-
[IqSiFile].
-
#id ⇒ Object
Session ID of this stream.
-
#id=(s) ⇒ Object
Set Session ID of this stream.
-
#initialize(id = nil, profile = nil, mime_type = nil) ⇒ IqSi
constructor
A new instance of IqSi.
-
#mime_type ⇒ Object
MIME type of this stream.
-
#mime_type=(s) ⇒ Object
Set MIME type of this stream.
-
#profile ⇒ Object
Stream profile, can indicate file-transfer.
-
#profile=(s) ⇒ Object
Set stream profile.
Methods inherited from XMPPElement
class_for_name_xmlns, #clone, force_xmlns, force_xmlns?, import, name_xmlns, name_xmlns_for_class, #parent=, #set_xml_lang, #typed_add, #xml_lang, #xml_lang=
Methods inherited from REXML::Element
#==, #delete_elements, #first_element, #first_element_text, #import, import, #replace_element_text, #typed_add
Constructor Details
#initialize(id = nil, profile = nil, mime_type = nil) ⇒ IqSi
Returns a new instance of IqSi.
19 20 21 22 23 24 25 |
# File 'lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb', line 19 def initialize(id=nil, profile=nil, mime_type=nil) super() self.id = id self.profile = profile self.mime_type = mime_type end |
Instance Method Details
#feature ⇒ Object
<feature/> child
- result
- IqFeature
73 74 75 |
# File 'lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb', line 73 def feature first_element('feature') end |
#file ⇒ Object
<file/> child
- result
- IqSiFile
66 67 68 |
# File 'lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb', line 66 def file first_element('file') end |
#id ⇒ Object
Session ID of this stream
29 30 31 |
# File 'lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb', line 29 def id attributes['id'] end |
#id=(s) ⇒ Object
Set Session ID of this stream
35 36 37 |
# File 'lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb', line 35 def id=(s) attributes['id'] = s end |
#mime_type ⇒ Object
MIME type of this stream
41 42 43 |
# File 'lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb', line 41 def mime_type attributes['mime-type'] end |
#mime_type=(s) ⇒ Object
Set MIME type of this stream
47 48 49 |
# File 'lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb', line 47 def mime_type=(s) attributes['mime-type'] = s end |
#profile ⇒ Object
Stream profile, can indicate file-transfer
53 54 55 |
# File 'lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb', line 53 def profile attributes['profile'] end |
#profile=(s) ⇒ Object
Set stream profile
59 60 61 |
# File 'lib/gems/xmpp4r-0.4/lib/xmpp4r/bytestreams/iq/si.rb', line 59 def profile=(s) attributes['profile'] = s end |