Class: Applitools::Dimension

Inherits:
Object
  • Object
show all
Defined in:
lib/eyes_selenium/eyes/dimension.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(width, height) ⇒ Dimension

Returns a new instance of Dimension.



4
5
6
7
# File 'lib/eyes_selenium/eyes/dimension.rb', line 4

def initialize(width, height)
  @width = width
  @height = height
end

Instance Attribute Details

#heightObject

Returns the value of attribute height.



3
4
5
# File 'lib/eyes_selenium/eyes/dimension.rb', line 3

def height
  @height
end

#widthObject

Returns the value of attribute width.



3
4
5
# File 'lib/eyes_selenium/eyes/dimension.rb', line 3

def width
  @width
end

Instance Method Details

#to_hashObject



9
10
11
# File 'lib/eyes_selenium/eyes/dimension.rb', line 9

def to_hash
  { width: width, height: height}
end

#valuesObject



12
13
14
# File 'lib/eyes_selenium/eyes/dimension.rb', line 12

def values
  [width, height]
end