Added DISTANCE to command generation

This commit is contained in:
w1n2k 2017-01-10 21:03:09 +03:00
parent 1b20a4c590
commit 44a596b12b
2 changed files with 76 additions and 64 deletions

View File

@ -45,7 +45,7 @@
"arguments":[
{
"name": "geojson",
"type": "geojson"
"type": "geojson"
}
]
},
@ -54,11 +54,11 @@
"arguments":[
{
"name": "lat",
"type": "double"
"type": "double"
},
{
"name": "lon",
"type": "double"
"type": "double"
},
{
"name": "z",
@ -72,19 +72,19 @@
"arguments":[
{
"name": "minlat",
"type": "double"
"type": "double"
},
{
"name": "minlon",
"type": "double"
"type": "double"
},
{
"name": "maxlat",
"type": "double"
"type": "double"
},
{
"name": "maxlon",
"type": "double"
"type": "double"
}
]
},
@ -93,7 +93,7 @@
"arguments":[
{
"name": "geohash",
"type": "geohash"
"type": "geohash"
}
]
},
@ -102,7 +102,7 @@
"arguments":[
{
"name": "value",
"type": "string"
"type": "string"
}
]
}
@ -483,6 +483,12 @@
"type": "pattern",
"optional": true
},
{
"command": "DISTANCE",
"name": [],
"type": [],
"optional": true
},
{
"command": "WHERE",
"name": ["field","min","max"],
@ -569,15 +575,15 @@
"arguments":[
{
"name": "key",
"type": "string"
"type": "string"
},
{
"name": "pattern",
"type": "pattern"
"type": "pattern"
},
{
"name": "meters",
"type": "double"
"type": "double"
}
]
}
@ -701,19 +707,19 @@
"arguments":[
{
"name": "minlat",
"type": "double"
"type": "double"
},
{
"name": "minlon",
"type": "double"
"type": "double"
},
{
"name": "maxlat",
"type": "double"
"type": "double"
},
{
"name": "maxlon",
"type": "double"
"type": "double"
}
]
},
@ -722,7 +728,7 @@
"arguments":[
{
"name": "geojson",
"type": "geojson"
"type": "geojson"
}
]
},
@ -731,15 +737,15 @@
"arguments":[
{
"name": "x",
"type": "double"
"type": "double"
},
{
"name": "y",
"type": "double"
"type": "double"
},
{
"name": "z",
"type": "double"
"type": "double"
}
]
},
@ -748,7 +754,7 @@
"arguments":[
{
"name": "quadkey",
"type": "string"
"type": "string"
}
]
},
@ -881,19 +887,19 @@
"arguments":[
{
"name": "minlat",
"type": "double"
"type": "double"
},
{
"name": "minlon",
"type": "double"
"type": "double"
},
{
"name": "maxlat",
"type": "double"
"type": "double"
},
{
"name": "maxlon",
"type": "double"
"type": "double"
}
]
},
@ -902,7 +908,7 @@
"arguments":[
{
"name": "geojson",
"type": "geojson"
"type": "geojson"
}
]
},
@ -911,15 +917,15 @@
"arguments":[
{
"name": "x",
"type": "double"
"type": "double"
},
{
"name": "y",
"type": "double"
"type": "double"
},
{
"name": "z",
"type": "double"
"type": "double"
}
]
},
@ -928,7 +934,7 @@
"arguments":[
{
"name": "quadkey",
"type": "string"
"type": "string"
}
]
},
@ -952,7 +958,7 @@
"arguments":[
{
"name": "parameter",
"type": "string"
"type": "string"
}
],
"group": "server"
@ -962,7 +968,7 @@
"arguments":[
{
"name": "parameter",
"type": "string"
"type": "string"
},
{
"name": "value",

View File

@ -207,7 +207,7 @@ var commandsJSON = `{
"arguments":[
{
"name": "geojson",
"type": "geojson"
"type": "geojson"
}
]
},
@ -216,11 +216,11 @@ var commandsJSON = `{
"arguments":[
{
"name": "lat",
"type": "double"
"type": "double"
},
{
"name": "lon",
"type": "double"
"type": "double"
},
{
"name": "z",
@ -234,19 +234,19 @@ var commandsJSON = `{
"arguments":[
{
"name": "minlat",
"type": "double"
"type": "double"
},
{
"name": "minlon",
"type": "double"
"type": "double"
},
{
"name": "maxlat",
"type": "double"
"type": "double"
},
{
"name": "maxlon",
"type": "double"
"type": "double"
}
]
},
@ -255,7 +255,7 @@ var commandsJSON = `{
"arguments":[
{
"name": "geohash",
"type": "geohash"
"type": "geohash"
}
]
},
@ -264,7 +264,7 @@ var commandsJSON = `{
"arguments":[
{
"name": "value",
"type": "string"
"type": "string"
}
]
}
@ -645,6 +645,12 @@ var commandsJSON = `{
"type": "pattern",
"optional": true
},
{
"command": "DISTANCE",
"name": [],
"type": [],
"optional": true
},
{
"command": "WHERE",
"name": ["field","min","max"],
@ -731,15 +737,15 @@ var commandsJSON = `{
"arguments":[
{
"name": "key",
"type": "string"
"type": "string"
},
{
"name": "pattern",
"type": "pattern"
"type": "pattern"
},
{
"name": "meters",
"type": "double"
"type": "double"
}
]
}
@ -863,19 +869,19 @@ var commandsJSON = `{
"arguments":[
{
"name": "minlat",
"type": "double"
"type": "double"
},
{
"name": "minlon",
"type": "double"
"type": "double"
},
{
"name": "maxlat",
"type": "double"
"type": "double"
},
{
"name": "maxlon",
"type": "double"
"type": "double"
}
]
},
@ -884,7 +890,7 @@ var commandsJSON = `{
"arguments":[
{
"name": "geojson",
"type": "geojson"
"type": "geojson"
}
]
},
@ -893,15 +899,15 @@ var commandsJSON = `{
"arguments":[
{
"name": "x",
"type": "double"
"type": "double"
},
{
"name": "y",
"type": "double"
"type": "double"
},
{
"name": "z",
"type": "double"
"type": "double"
}
]
},
@ -910,7 +916,7 @@ var commandsJSON = `{
"arguments":[
{
"name": "quadkey",
"type": "string"
"type": "string"
}
]
},
@ -1043,19 +1049,19 @@ var commandsJSON = `{
"arguments":[
{
"name": "minlat",
"type": "double"
"type": "double"
},
{
"name": "minlon",
"type": "double"
"type": "double"
},
{
"name": "maxlat",
"type": "double"
"type": "double"
},
{
"name": "maxlon",
"type": "double"
"type": "double"
}
]
},
@ -1064,7 +1070,7 @@ var commandsJSON = `{
"arguments":[
{
"name": "geojson",
"type": "geojson"
"type": "geojson"
}
]
},
@ -1073,15 +1079,15 @@ var commandsJSON = `{
"arguments":[
{
"name": "x",
"type": "double"
"type": "double"
},
{
"name": "y",
"type": "double"
"type": "double"
},
{
"name": "z",
"type": "double"
"type": "double"
}
]
},
@ -1090,7 +1096,7 @@ var commandsJSON = `{
"arguments":[
{
"name": "quadkey",
"type": "string"
"type": "string"
}
]
},
@ -1114,7 +1120,7 @@ var commandsJSON = `{
"arguments":[
{
"name": "parameter",
"type": "string"
"type": "string"
}
],
"group": "server"
@ -1124,7 +1130,7 @@ var commandsJSON = `{
"arguments":[
{
"name": "parameter",
"type": "string"
"type": "string"
},
{
"name": "value",