Class: AgentXmpp::Xmpp::XDataItem
- Inherits:
-
Element
- Object
- REXML::Element
- Element
- AgentXmpp::Xmpp::XDataItem
- Defined in:
- lib/agent_xmpp/xmpp/x_data.rb
Overview
Instance Method Summary collapse
-
#add_field_with_value(var, value, type = nil) ⇒ Object
.….….….….….….….….….….….….….….….….….….….….….….….….….
-
#fields ⇒ Object
.….….….….….….….….….….….….….….….….….….….….….….….….….
Methods inherited from Element
#<<, class_for_name_xmlns, #clone, import, #initialize, name_xmlns, name_xmlns_for_class, #parent=, #set_xml_lang, #typed_add, #xml_lang, #xml_lang=, xmpp_attribute, xmpp_child
Methods inherited from REXML::Element
#delete_elements, #first_element, #first_element_text, #import, import, #replace_element_text, #typed_add
Constructor Details
This class inherits a constructor from AgentXmpp::Xmpp::Element
Instance Method Details
#add_field_with_value(var, value, type = nil) ⇒ Object
.….….….….….….….….….….….….….….….….….….….….….….….….….
344 345 346 347 348 |
# File 'lib/agent_xmpp/xmpp/x_data.rb', line 344 def add_field_with_value(var, value, type=nil) field = XDataField.new(var, type) field.values = value self << field end |
#fields ⇒ Object
.….….….….….….….….….….….….….….….….….….….….….….….….….
339 340 341 |
# File 'lib/agent_xmpp/xmpp/x_data.rb', line 339 def fields elements.to_a('field') end |