Class: Paperclip::GeometryDetector
- Inherits:
-
Object
- Object
- Paperclip::GeometryDetector
- Defined in:
- lib/paperclip/geometry_detector_factory.rb
Instance Method Summary collapse
-
#initialize(file) ⇒ GeometryDetector
constructor
A new instance of GeometryDetector.
- #make ⇒ Object
Constructor Details
#initialize(file) ⇒ GeometryDetector
Returns a new instance of GeometryDetector.
3 4 5 6 |
# File 'lib/paperclip/geometry_detector_factory.rb', line 3 def initialize(file) @file = file raise_if_blank_file end |
Instance Method Details
#make ⇒ Object
8 9 10 11 |
# File 'lib/paperclip/geometry_detector_factory.rb', line 8 def make geometry = GeometryParser.new(geometry_string.strip).make geometry || raise(Errors::NotIdentifiedByImageMagickError.new) end |