Class: Bulk::Collection::Errors

Inherits:
AbstractCollection show all
Defined in:
lib/bulk/collection.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from AbstractCollection

#clear, #delete, #empty?, #get, #ids, #length

Constructor Details

#initialize(collection) ⇒ Errors

Returns a new instance of Errors.



17
18
19
20
# File 'lib/bulk/collection.rb', line 17

def initialize(collection)
  @collection = collection
  super()
end

Instance Attribute Details

#collectionObject (readonly)

Returns the value of attribute collection.



15
16
17
# File 'lib/bulk/collection.rb', line 15

def collection
  @collection
end

Instance Method Details

#set(id, error, data = nil) ⇒ Object



22
23
24
# File 'lib/bulk/collection.rb', line 22

def set(id, error, data = nil)
  super(id, Error.new(error, data))
end