Class: Exchanger::UpdateItem::Request
- Inherits:
-
Operation::Request
- Object
- Operation::Request
- Exchanger::UpdateItem::Request
- Defined in:
- lib/exchanger/operations/update_item.rb
Instance Attribute Summary collapse
-
#items ⇒ Object
Returns the value of attribute items.
-
#send_meeting_invitations_or_cancellations ⇒ Object
Returns the value of attribute send_meeting_invitations_or_cancellations.
Attributes inherited from Operation::Request
Instance Method Summary collapse
-
#reset ⇒ Object
Reset request options to defaults.
- #to_xml ⇒ Object
Methods inherited from Operation::Request
#action, #headers, #initialize
Constructor Details
This class inherits a constructor from Exchanger::Operation::Request
Instance Attribute Details
#items ⇒ Object
Returns the value of attribute items.
8 9 10 |
# File 'lib/exchanger/operations/update_item.rb', line 8 def items @items end |
#send_meeting_invitations_or_cancellations ⇒ Object
Returns the value of attribute send_meeting_invitations_or_cancellations.
8 9 10 |
# File 'lib/exchanger/operations/update_item.rb', line 8 def send_meeting_invitations_or_cancellations @send_meeting_invitations_or_cancellations end |
Instance Method Details
#reset ⇒ Object
Reset request options to defaults.
11 12 13 |
# File 'lib/exchanger/operations/update_item.rb', line 11 def reset @items = [] end |
#to_xml ⇒ Object
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/exchanger/operations/update_item.rb', line 15 def to_xml Nokogiri::XML::Builder.new do |xml| xml.send("soap:Envelope", "xmlns:soap" => NS["soap"], "xmlns:t" => NS["t"], "xmlns:xsi" => NS["xsi"], "xmlns:xsd" => NS["xsd"]) do xml.send("soap:Body") do xml.UpdateItem(update_item_attributes) do xml.ItemChanges do items.each do |item| item_change = item.to_xml_change item_change.add_namespace_definition("t", NS["t"]) item_change.namespace = item_change.namespace_definitions[0] xml << item_change.to_s end end end end end end end |