class PicturehouseUk::Internal::Website
fetches pages from the picturehouse.com website
Public Instance Methods
cinema(id)
click to toggle source
get the cinema page with showings for passed id @return [String]
# File lib/picturehouse_uk/internal/website.rb, line 11 def cinema(id) get("cinema/#{id}") end
home()
click to toggle source
get the home page @return [String]
# File lib/picturehouse_uk/internal/website.rb, line 33 def home get(nil) end
info(id)
click to toggle source
get the cinema contact information page for passed id @return [String]
# File lib/picturehouse_uk/internal/website.rb, line 25 def info(id) get("cinema/info/#{id}") rescue OpenURI::HTTPError '' end
whats_on(id)
click to toggle source
get the cinema screenings page for passed id @return [String]
# File lib/picturehouse_uk/internal/website.rb, line 17 def whats_on(id) get("cinema/#{id}/Whats_On") rescue OpenURI::HTTPError '' end
Private Instance Methods
get(path)
click to toggle source
# File lib/picturehouse_uk/internal/website.rb, line 39 def get(path) # SSL verification doesn't work on picturehouses.com open("https://www.picturehouses.com/#{path}", ssl_verify_mode: OpenSSL::SSL::VERIFY_NONE).read end