require 'structured_log' array = %w/foo bar baz bat/ StructuredLog.open('array.xml') do |log| log.put_array('my_array', array) end