Class: CardDB::DeckImportFormatTestPayload

Inherits:
DeckHydrateEntriesPayload show all
Defined in:
lib/carddb/collection.rb

Instance Attribute Summary

Attributes inherited from Resource

#client, #data

Instance Method Summary collapse

Methods inherited from DeckHydrateEntriesPayload

#ambiguous, #entries, #unmatched

Methods inherited from Resource

#[], #initialize, #key?, #to_h, #to_json

Constructor Details

This class inherits a constructor from CardDB::Resource

Instance Method Details

#detectionObject



1509
1510
1511
# File 'lib/carddb/collection.rb', line 1509

def detection
  @detection ||= data['detection'] ? DeckImportFormatDetection.new(data['detection'], client: client) : nil
end

#parse_errorsObject



1513
1514
1515
# File 'lib/carddb/collection.rb', line 1513

def parse_errors
  @parse_errors ||= (data['parseErrors'] || []).map { |issue| DeckImportIssue.new(issue, client: client) }
end