Class: TomatoPower::Actor

Inherits:
Object
  • Object
show all
Defined in:
lib/tomato_power/movie/actor.rb

Overview

Actor of a movie.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(actor = {}) ⇒ Actor

Returns a new instance of Actor.



7
8
9
10
11
# File 'lib/tomato_power/movie/actor.rb', line 7

def initialize actor={}
  @id = actor["id"]
  @name = actor["name"]
  @characters = actor["characters"]
end

Instance Attribute Details

#charactersObject (readonly)

Returns the value of attribute characters.



5
6
7
# File 'lib/tomato_power/movie/actor.rb', line 5

def characters
  @characters
end

#idObject (readonly)

Returns the value of attribute id.



5
6
7
# File 'lib/tomato_power/movie/actor.rb', line 5

def id
  @id
end

#nameObject (readonly)

Returns the value of attribute name.



5
6
7
# File 'lib/tomato_power/movie/actor.rb', line 5

def name
  @name
end