Sha256: 231f56092b0a78bd6bdff648a66fc0f0ec3e19c0c103fdaffb8110a3064cf0be

Contents?: true

Size: 478 Bytes

Versions: 2

Compression:

Stored size: 478 Bytes

Contents

module Thanos
  class Story
    attr_reader :title, :description, :type, :resource_uri, :thumbnail,
      :creators, :characters, :events, :series, :comics

    def initialize(args)
      @characters = args[:characters]
      @creators = args[:creators]
      @events = args[:events]
      @series = args[:series]
      @comics = args[:comics]

      args[:attributes].each do |attribute, value|
        instance_variable_set("@#{attribute}", value)
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
thanos-0.6.0 lib/thanos/resources/story.rb
thanos-0.5.0 lib/thanos/resources/story.rb