Class: FanartApi::Movie

Inherits:
Base
  • Object
show all
Defined in:
lib/fanart_api/movie.rb

Overview

Instance Method Summary collapse

Methods inherited from Base

#api_key, #initialize, #shared_uri

Constructor Details

This class inherits a constructor from FanartApi::Base

Instance Method Details

#find(id, type = 'all', sort = '1', limit = '2') ⇒ Object



3
4
5
# File 'lib/fanart_api/movie.rb', line 3

def find(id, type = 'all', sort = '1', limit = '2')
  self.class.get("movie#{shared_uri(id, type, sort, limit)}")
end

#update(timestamp = (Time.now - 172800).to_i) ⇒ Object



7
8
9
# File 'lib/fanart_api/movie.rb', line 7

def update(timestamp = (Time.now - 172800).to_i)
  self.class.get("newmovies/#{api_key}/#{timestamp}")
end