Class: Media::Size

Inherits:
Object
  • Object
show all
Defined in:
lib/media/size.rb

Instance Method Summary collapse

Constructor Details

#initialize(args) ⇒ Size

Returns a new instance of Size.



3
4
5
6
# File 'lib/media/size.rb', line 3

def initialize(args)
  @width  = args.fetch(:width)
  @height = args.fetch(:height)
end

Instance Method Details

#to_sObject



8
9
10
# File 'lib/media/size.rb', line 8

def to_s
  [@width, @height].join('x')
end