Class: Starwars::Film
- Inherits:
-
Base
- Object
- OpenStruct
- Base
- Starwars::Film
- Defined in:
- lib/starwars/resources/film.rb,
lib/starwars.rb
Overview
A Film resource is an single film.
Constant Summary collapse
- RESOURCE_NAME =
Define the source name in the starwars api
'films'
Constants inherited from Base
Instance Method Summary collapse
-
#characters ⇒ Array<Person>
List of people.
-
#director ⇒ String
The name of the director of this film.
-
#episode_id ⇒ Integer
The episode number of this film.
-
#opening_crawl ⇒ String
The opening paragraphs at the beginning of this film.
-
#planets ⇒ Array<Person>
List of planets.
-
#producer ⇒ String
The name(s) of the producer(s) of this film.
-
#species ⇒ Array<Specie>
List of species.
-
#starships ⇒ Array<Starship>
List of starships.
-
#title ⇒ String
The title of this film.
-
#vehicles ⇒ Array<Vehicle>
List of vehicles.
Methods inherited from Base
#==, #created, #edited, fetch, #fetch, fetch_all, #id, #request_attributes, #url
Methods inherited from OpenStruct
Instance Method Details
#characters ⇒ Array<Person>
List of people
49 |
# File 'lib/starwars/resources/film.rb', line 49 collection :characters, class: Starwars::Person, deserialize: ->(_, fragment, _) { Person.new(url: fragment) } |
#director ⇒ String
The name of the director of this film
28 |
# File 'lib/starwars/resources/film.rb', line 28 property :director |
#episode_id ⇒ Integer
The episode number of this film
42 |
# File 'lib/starwars/resources/film.rb', line 42 property :episode_id, type: Integer |
#opening_crawl ⇒ String
The opening paragraphs at the beginning of this film
21 |
# File 'lib/starwars/resources/film.rb', line 21 property :opening_crawl |
#planets ⇒ Array<Person>
List of planets
56 |
# File 'lib/starwars/resources/film.rb', line 56 collection :planets, class: Starwars::Planet, deserialize: ->(_, fragment, _) { Planet.new(url: fragment) } |
#producer ⇒ String
The name(s) of the producer(s) of this film. Comma seperated
35 |
# File 'lib/starwars/resources/film.rb', line 35 property :producer |
#species ⇒ Array<Specie>
List of species
77 |
# File 'lib/starwars/resources/film.rb', line 77 collection :species, class: Starwars::Specie, deserialize: ->(_, fragment, _) { Specie.new(url: fragment) } |
#starships ⇒ Array<Starship>
List of starships
63 |
# File 'lib/starwars/resources/film.rb', line 63 collection :starships, class: Starwars::Starship, deserialize: ->(_, fragment, _) { Starship.new(url: fragment) } |
#title ⇒ String
The title of this film
14 |
# File 'lib/starwars/resources/film.rb', line 14 property :title |