Class: Jabber::PubSub::Items

Inherits:
XMPPElement show all
Includes:
Enumerable
Defined in:
lib/xmpp4r/pubsub/children/items.rb

Overview

Items a collection of Items

Direct Known Subclasses

EventItems

Instance Method Summary collapse

Methods inherited from XMPPElement

class_for_name_xmlns, #clone, force_xmlns, force_xmlns?, import, #initialize, name_xmlns, name_xmlns_for_class, #parent=, #set_xml_lang, #typed_add, #xml_lang, #xml_lang=

Methods inherited from REXML::Element

#==, #delete_elements, #each_elements, #first_element, #first_element_content, #first_element_text, #import, import, #replace_element_content, #replace_element_text, #typed_add

Constructor Details

This class inherits a constructor from Jabber::XMPPElement

Instance Method Details

#each(&block) ⇒ Object



39
40
41
# File 'lib/xmpp4r/pubsub/children/items.rb', line 39

def each(&block)
  items.each(&block)
end

#itemsObject



35
36
37
# File 'lib/xmpp4r/pubsub/children/items.rb', line 35

def items
  get_elements("item")
end

#max_itemsObject



28
29
30
# File 'lib/xmpp4r/pubsub/children/items.rb', line 28

def max_items
  attributes['max_items']
end

#max_items=(mymaxitems) ⇒ Object



31
32
33
# File 'lib/xmpp4r/pubsub/children/items.rb', line 31

def max_items=(mymaxitems)
  attributes['max_items'] = mymaxitems.to_s
end

#nodeObject



16
17
18
# File 'lib/xmpp4r/pubsub/children/items.rb', line 16

def node
  attributes['node']
end

#node=(mynodename) ⇒ Object



19
20
21
# File 'lib/xmpp4r/pubsub/children/items.rb', line 19

def node=(mynodename)
  attributes['node'] = mynodename
end

#subidObject



22
23
24
# File 'lib/xmpp4r/pubsub/children/items.rb', line 22

def subid
  attributes['subid']
end

#subid=(mysubid) ⇒ Object



25
26
27
# File 'lib/xmpp4r/pubsub/children/items.rb', line 25

def subid=(mysubid)
  attributes['subid'] = mysubid.to_s
end