Sha256: a6caf147b9b2083b4b5d94fa42710af156d737c60608217fbc30c98f404564e4
Contents?: true
Size: 865 Bytes
Versions: 6
Compression:
Stored size: 865 Bytes
Contents
require 'open-uri' module OdeonUk # Internal utility classes: Do not use # @api private module Html # Utility class to make calls to the odeon website class Website # cinema page # @param [Integer] cinema_id website id of the cinema # @return [String] html of the page def cinema(cinema_id) get("cinemas/odeon/#{cinema_id}/") end # showtimes page for a single cinema # @param [Integer] cinema_id website id of the cinema # @return [String] html of the page def showtimes(cinema_id) get("showtimes/week/#{cinema_id}/?siteId=#{cinema_id}") end # sitemap page # @return [String] html of the page def sitemap get('sitemap/') end private def get(path) URI("http://www.odeon.co.uk/#{path}").read end end end end
Version data entries
6 entries across 6 versions & 1 rubygems