class ComicVine::Resource::Person

Extends {ComicVine::Resource::Person} to add mongoid functions @since 0.1.2

Public Instance Methods

count_of_isssue_appearances() click to toggle source

Accounts for ComicVine's miss-spelling of issue in key. returns count_of_issue_appearances @return [Integer] @since 0.1.0

# File lib/comicvine/mongo.rb, line 635
def count_of_isssue_appearances
  self[:count_of_issue_appearances]
end
count_of_isssue_appearances=(value) click to toggle source

Accounts for ComicVine's miss-spelling of issue in key. Maps count_of_isssue_appearances to count_of_issue_appearances @param value [Integer] @since 0.1.0

# File lib/comicvine/mongo.rb, line 627
def count_of_isssue_appearances=(value)
  self[:count_of_issue_appearances] = value
end
death=(value) click to toggle source

Override to handle ComicVine hash results @param value [DateTime] @since 0.1.0

Calls superclass method
# File lib/comicvine/mongo.rb, line 611
def death=(value)
  if value.nil?
    # Do nothing
  elsif value.kind_of?(Hash) && value.has_key?('date')
    # Translate the string
    #TODO: Parse the remaining keys: timezone_type && timezone into correct dateTime. See person: 2756
    super DateTime.parse(value['date'])
  elsif value.kind_of?(DateTime)
    super
  end
end