Class: CardDB::RulesetVersion
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
#active? ⇒ Boolean
2096
|
# File 'lib/carddb/collection.rb', line 2096
def active? = status == 'ACTIVE'
|
#card_dataset_id ⇒ Object
2080
|
# File 'lib/carddb/collection.rb', line 2080
def card_dataset_id = data['cardDatasetId']
|
#card_dataset_version_id ⇒ Object
2081
|
# File 'lib/carddb/collection.rb', line 2081
def card_dataset_version_id = data['cardDatasetVersionId']
|
#changelog ⇒ Object
2088
|
# File 'lib/carddb/collection.rb', line 2088
def changelog = data['changelog']
|
#created_at ⇒ Object
2093
|
# File 'lib/carddb/collection.rb', line 2093
def created_at = parse_time(data['createdAt'])
|
#created_by_account_id ⇒ Object
2089
|
# File 'lib/carddb/collection.rb', line 2089
def created_by_account_id = data['createdByAccountId']
|
#draft? ⇒ Boolean
2095
|
# File 'lib/carddb/collection.rb', line 2095
def draft? = status == 'DRAFT'
|
#effective_at ⇒ Object
2087
|
# File 'lib/carddb/collection.rb', line 2087
def effective_at = parse_time(data['effectiveAt'])
|
#id ⇒ Object
2075
|
# File 'lib/carddb/collection.rb', line 2075
def id = data['id']
|
#published_at ⇒ Object
2091
|
# File 'lib/carddb/collection.rb', line 2091
def published_at = parse_time(data['publishedAt'])
|
#published_by_account_id ⇒ Object
2090
|
# File 'lib/carddb/collection.rb', line 2090
def published_by_account_id = data['publishedByAccountId']
|
#rules ⇒ Object
2079
|
# File 'lib/carddb/collection.rb', line 2079
def rules = data['rules'] || {}
|
#rules_fingerprint ⇒ Object
2086
|
# File 'lib/carddb/collection.rb', line 2086
def rules_fingerprint = data['rulesFingerprint']
|
#ruleset_id ⇒ Object
2076
|
# File 'lib/carddb/collection.rb', line 2076
def ruleset_id = data['rulesetId']
|
#section_definitions ⇒ Object
2098
2099
2100
2101
2102
|
# File 'lib/carddb/collection.rb', line 2098
def section_definitions
@section_definitions ||= (data['sectionDefinitions'] || []).map do |definition|
DeckSectionDefinition.new(definition, client: client)
end
end
|
#source_dataset_id ⇒ Object
2082
|
# File 'lib/carddb/collection.rb', line 2082
def source_dataset_id = data['sourceDatasetId']
|
#source_dataset_record_id ⇒ Object
2084
|
# File 'lib/carddb/collection.rb', line 2084
def source_dataset_record_id = data['sourceDatasetRecordId']
|
#source_dataset_version_id ⇒ Object
2083
|
# File 'lib/carddb/collection.rb', line 2083
def source_dataset_version_id = data['sourceDatasetVersionId']
|
#source_record_identifier ⇒ Object
2085
|
# File 'lib/carddb/collection.rb', line 2085
def source_record_identifier = data['sourceRecordIdentifier']
|
#status ⇒ Object
2078
|
# File 'lib/carddb/collection.rb', line 2078
def status = data['status']
|
#superseded_at ⇒ Object
2092
|
# File 'lib/carddb/collection.rb', line 2092
def superseded_at = parse_time(data['supersededAt'])
|
#updated_at ⇒ Object
2094
|
# File 'lib/carddb/collection.rb', line 2094
def updated_at = parse_time(data['updatedAt'])
|
#version_label ⇒ Object
2077
|
# File 'lib/carddb/collection.rb', line 2077
def version_label = data['versionLabel']
|