class Depots
Public Instance Methods
addDepots(xCoordinate, yCoordinate, depotAttributeObj)
click to toggle source
Longitude => xCoordinate, Latitude => yCoordinate
# File lib/arcgis_vrps/depots.rb, line 3 def addDepots (xCoordinate, yCoordinate, depotAttributeObj) my_depot = { :geometry => { :x => xCoordinate, :y => yCoordinate }, :attributes => depotAttributeObj } if @depotArr.nil? @depotArr = [] end @depotArr.push(my_depot) end
getDepotArr()
click to toggle source
# File lib/arcgis_vrps/depots.rb, line 18 def getDepotArr return @depotArr end
getDepotAttributeObj(depotName, timeStart, timeEnd)
click to toggle source
# File lib/arcgis_vrps/depots.rb, line 22 def getDepotAttributeObj(depotName, timeStart, timeEnd) depotAttributeObj = { :Name => depotName, :TimeWindowStart1 => timeStart, :TimeWindowEnd1 => timeEnd } return depotAttributeObj end
getDepotObj(wkid)
click to toggle source
return depotAttributeObj
end
# File lib/arcgis_vrps/depots.rb, line 43 def getDepotObj (wkid) if wkid.nil? depotObj = { :features => @depotArr } else depotObj = { :spatialReference => { :wkid => wkid }, :features => @depotArr } end return depotObj end