Class: Thron::Entity::Image

Inherits:
Base
  • Object
show all
Defined in:
lib/thron/entity/image.rb

Constant Summary

Constants inherited from Base

Base::DATE_REGEX, Base::TIME_REGEX

Instance Method Summary collapse

Methods inherited from Base

factory, #to_h, #to_payload

Constructor Details

#initialize(hash = {}) ⇒ Image



4
5
6
7
8
9
10
11
# File 'lib/thron/entity/image.rb', line 4

def initialize(hash = {})
  super
  @path = hash.delete(:path)
  if valid_path?
    fetch_mime_type
    fetch_buffer
  end
end