Method: JSS::Locatable#location_xml

Defined in:
lib/jss/api_object/locatable.rb

#location_xmlREXML::Element

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Return a REXML <location> element to be included in the rest_xml of objects that have a Location subset



271
272
273
274
275
276
277
278
279
280
281
282
# File 'lib/jss/api_object/locatable.rb', line 271

def location_xml
  location = REXML::Element.new('location')
  location.add_element('building').text = @building
  location.add_element('department').text = @department
  location.add_element('email_address').text = @email_address
  location.add_element('position').text = @position
  location.add_element('phone').text = @phone
  location.add_element('real_name').text = @real_name
  location.add_element('room').text = @room
  location.add_element('username').text = @username
  return location
end