Class: MiniMagick::Image::Info
- Inherits:
-
Object
- Object
- MiniMagick::Image::Info
- Defined in:
- lib/mini_magick/image/info.rb
Constant Summary collapse
- ASCII_ENCODED_EXIF_KEYS =
%w[ExifVersion FlashPixVersion]
Instance Method Summary collapse
- #[](value, *args) ⇒ Object
- #clear ⇒ Object
-
#initialize(path) ⇒ Info
constructor
A new instance of Info.
Constructor Details
#initialize(path) ⇒ Info
Returns a new instance of Info.
7 8 9 10 |
# File 'lib/mini_magick/image/info.rb', line 7 def initialize(path) @path = path @info = {} end |
Instance Method Details
#[](value, *args) ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'lib/mini_magick/image/info.rb', line 12 def [](value, *args) case value when "format", "width", "height", "dimensions", "size" cheap_info(value) when "colorspace" colorspace when "mime_type" mime_type when "resolution" resolution(*args) when "signature" signature when /^EXIF\:/i raw_exif(value) when "exif" exif else raw(value) end end |
#clear ⇒ Object
33 34 35 |
# File 'lib/mini_magick/image/info.rb', line 33 def clear @info.clear end |