Class: CardDB::BulkImportResult
Instance Attribute Summary
Attributes inherited from Resource
#client, #data
Instance Method Summary
collapse
Methods inherited from Resource
#[], #initialize, #key?, #to_h, #to_json
Instance Method Details
#created_fields ⇒ Object
1009
1010
1011
|
# File 'lib/carddb/collection.rb', line 1009
def created_fields
@created_fields ||= (data['createdFields'] || []).map { |field| ObjectField.new(field, client: client) }
end
|
#errors ⇒ Object
1005
1006
1007
|
# File 'lib/carddb/collection.rb', line 1005
def errors
@errors ||= (data['errors'] || []).map { |error| BulkRecordError.new(error, client: client) }
end
|
#inserted ⇒ Object
995
996
997
|
# File 'lib/carddb/collection.rb', line 995
def inserted
@inserted ||= (data['inserted'] || []).map { |record| Record.new(record, client: client) }
end
|
#skipped ⇒ Object
1003
|
# File 'lib/carddb/collection.rb', line 1003
def skipped = data['skipped']
|
#stats ⇒ Object
1013
1014
1015
|
# File 'lib/carddb/collection.rb', line 1013
def stats
@stats ||= data['stats'] ? ImportStats.new(data['stats'], client: client) : nil
end
|
#updated ⇒ Object
999
1000
1001
|
# File 'lib/carddb/collection.rb', line 999
def updated
@updated ||= (data['updated'] || []).map { |record| Record.new(record, client: client) }
end
|