Class: Mapstatic::Tile

Inherits:
Object
  • Object
show all
Defined in:
lib/mapstatic/tile.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(x, y, zoom) ⇒ Tile

Returns a new instance of Tile.



6
7
8
9
10
# File 'lib/mapstatic/tile.rb', line 6

def initialize(x,y,zoom)
  @x = x.floor
  @y = y.floor
  @zoom = zoom
end

Instance Attribute Details

#xObject

Returns the value of attribute x.



4
5
6
# File 'lib/mapstatic/tile.rb', line 4

def x
  @x
end

#yObject

Returns the value of attribute y.



4
5
6
# File 'lib/mapstatic/tile.rb', line 4

def y
  @y
end

#zoomObject

Returns the value of attribute zoom.



4
5
6
# File 'lib/mapstatic/tile.rb', line 4

def zoom
  @zoom
end