Class: Gingham::Position

Inherits:
Object
  • Object
show all
Defined in:
lib/gingham/position.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(x, y, z) ⇒ Position

Returns a new instance of Position.



5
6
7
# File 'lib/gingham/position.rb', line 5

def initialize(x, y, z)
  @x, @y, @z = x, y, z
end

Instance Attribute Details

#xObject

Returns the value of attribute x.



3
4
5
# File 'lib/gingham/position.rb', line 3

def x
  @x
end

#yObject

Returns the value of attribute y.



3
4
5
# File 'lib/gingham/position.rb', line 3

def y
  @y
end

#zObject

Returns the value of attribute z.



3
4
5
# File 'lib/gingham/position.rb', line 3

def z
  @z
end