Class: RedSnow::Location

Inherits:
Object
  • Object
show all
Defined in:
lib/redsnow/parseresult.rb

Overview

Array of possibly non-continuous blocks of the source API Blueprint.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(location) ⇒ Location

Returns a new instance of Location.

Parameters:

  • location (json)


63
64
65
66
# File 'lib/redsnow/parseresult.rb', line 63

def initialize(location)
  @length = location['length']
  @index = location['index']
end

Instance Attribute Details

#indexObject

Returns the value of attribute index.



59
60
61
# File 'lib/redsnow/parseresult.rb', line 59

def index
  @index
end

#lengthObject

Returns the value of attribute length.



60
61
62
# File 'lib/redsnow/parseresult.rb', line 60

def length
  @length
end