lib/rews/item.rb
# return a list of Item objects given a hash formed from an Items element
return a list of Item objects given a hash formed from an Items element
return a list of Item objects given a hash formed from an Items element
def read_items(client, items)
      return [] if !items
      items.map do |item_class,items_of_class|
        items_of_class = [items_of_class] if !items_of_class.is_a?(Array)
        items_of_class.map do |item|
          Item.new(client, item_class, item)
        end
      end.flatten
    end
def read_items ( client , items ) return [ ] if ! items items . map do | item_class , items_of_class | items_of_class = [ items_of_class ] if ! items_of_class . is_a? ( Array ) items_of_class . map do | item | Item . new ( client , item_class , item ) end end . flatten end
return a list of Item objects given a hash formed from an Items element
return a list of Item objects given a hash formed from an Items element
client
<not_specific>
items
<not_specific>