Class: Mws::Apis::Feeds::Feed::Builder

Inherits:
Object
  • Object
show all
Defined in:
lib/mws/apis/feeds/feed.rb

Instance Method Summary collapse

Constructor Details

#initialize(feed, messages) ⇒ Builder

Returns a new instance of Builder.



57
58
59
60
# File 'lib/mws/apis/feeds/feed.rb', line 57

def initialize(feed, messages)
  @feed = feed
  @messages = messages
end

Instance Method Details

#message(resource, operation_type = nil) ⇒ Object



62
63
64
# File 'lib/mws/apis/feeds/feed.rb', line 62

def message(resource, operation_type=nil)
  (@messages << Message.new(@messages.length + 1, @feed.message_type, resource, operation_type)).last
end