Class: Lebowski::Rect
- Inherits:
-
Object
- Object
- Lebowski::Rect
- Defined in:
- lib/lebowski/core.rb
Instance Attribute Summary (collapse)
-
- (Object) height
Returns the value of attribute height.
-
- (Object) width
Returns the value of attribute width.
-
- (Object) x
Returns the value of attribute x.
-
- (Object) y
Returns the value of attribute y.
Instance Method Summary (collapse)
-
- (Rect) initialize(width, height, x, y)
constructor
A new instance of Rect.
- - (Object) to_s
Constructor Details
- (Rect) initialize(width, height, x, y)
A new instance of Rect
7 8 9 10 11 12 |
# File 'lib/lebowski/core.rb', line 7 def initialize(width, height, x, y) @width = width @height = height @x = x @y = y end |
Instance Attribute Details
- (Object) height
Returns the value of attribute height
5 6 7 |
# File 'lib/lebowski/core.rb', line 5 def height @height end |
- (Object) width
Returns the value of attribute width
5 6 7 |
# File 'lib/lebowski/core.rb', line 5 def width @width end |
- (Object) x
Returns the value of attribute x
5 6 7 |
# File 'lib/lebowski/core.rb', line 5 def x @x end |
- (Object) y
Returns the value of attribute y
5 6 7 |
# File 'lib/lebowski/core.rb', line 5 def y @y end |
Instance Method Details
- (Object) to_s
14 15 16 |
# File 'lib/lebowski/core.rb', line 14 def to_s() return "Rect<width: #{width}, height: #{height}, x: #{x}, y: #{y}>" end |