Class: Kafka::Batch

Inherits:
Object
  • Object
show all
Defined in:
lib/kafka/batch.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeBatch

Returns a new instance of Batch.



20
21
22
# File 'lib/kafka/batch.rb', line 20

def initialize
  self.messages = []
end

Instance Attribute Details

#messagesObject

Returns the value of attribute messages.



18
19
20
# File 'lib/kafka/batch.rb', line 18

def messages
  @messages
end

Instance Method Details

#<<(message) ⇒ Object



24
25
26
# File 'lib/kafka/batch.rb', line 24

def << (message)
  self.messages << message
end