class EPUB::OCF::PhysicalContainer::UnpackedURI
Public Class Methods
Source
# File lib/epub/ocf/physical_container/unpacked_uri.rb, line 12 def initialize(container_path) super(URI(container_path)) end
EPUB
URI: example.net/path/to/book/ container.xml: example.net/path/to/book/META-INF/container.xml @param [URI, String] container_path URI of EPUB
container’s root directory.
For exapmle, <code>"http://example.net/path/to/book/"</code>, which should contain <code>"http://example.net/path/to/book/META-INF/container.xml"</code> as its container.xml file. Note that this should end with "/"(slash).
Calls superclass method
Public Instance Methods
Source
# File lib/epub/ocf/physical_container/unpacked_uri.rb, line 16 def open yield self end
Source
# File lib/epub/ocf/physical_container/unpacked_uri.rb, line 20 def read(path_name) (@container_path + path_name).read rescue ::OpenURI::HTTPError => error raise NoEntry.from_error(error) end