Class: CardDB::ScanTemplateResolution

Inherits:
Resource
  • Object
show all
Defined in:
lib/carddb/collection.rb

Direct Known Subclasses

ScanTemplatePayload

Instance Attribute Summary

Attributes inherited from Resource

#client, #data

Instance Method Summary collapse

Methods inherited from Resource

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

Constructor Details

This class inherits a constructor from CardDB::Resource

Instance Method Details

#templateObject



1148
1149
1150
# File 'lib/carddb/collection.rb', line 1148

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

#warningsObject



1152
1153
1154
# File 'lib/carddb/collection.rb', line 1152

def warnings
  @warnings ||= (data['warnings'] || []).map { |warning| ScanTemplateWarning.new(warning, client: client) }
end