{ "about": { "trial": false, "author": { "name": "EMQ", "email": "contact@emqx.io", "company": "EMQ Technologies Co., Ltd", "website": "https://www.emqx.io" }, "helpUrl": { "en_US": "https://ekuiper.org/docs/en/latest/sqls/custom_functions.html", "zh_CN": "https://ekuiper.org/docs/zh/latest/sqls/custom_functions.html" }, "description": { "en_US": "", "zh_CN": "" } }, "libs": ["github.com/mmcloughlin/geohash@master"], "name":"geohash", "functions": [{ "name": "geohashEncode", "example": "geohashEncode(la,lo)", "hint": { "en_US": "Encode latitude and longitude as characters", "zh_CN": "将经纬度编码为字符" }, "args": [ { "name": "latitude", "optional": false, "control": "field", "type": "string", "hint": { "en_US": "Input latitude", "zh_CN": "输入经度" }, "label": { "en_US": "Latitude", "zh_CN": "经度" } }, { "name": "longitude", "optional": false, "control": "field", "type": "string", "hint": { "en_US": "Input longitude", "zh_CN": "输入纬度" }, "label": { "en_US": "Longitude", "zh_CN": "输入纬度" } } ], "return": { "type": "int", "hint": { "en_US": "Encoded string", "zh_CN": "编码字符" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash Encode", "zh_CN": "Geohash 编码" } } }, { "name": "geohashEncodeInt", "example": "geohashEncodeInt(la,lo )", "hint": { "en_US": "Encode latitude and longitude as numbers", "zh_CN": "将经纬度编码为数字" }, "args": [ { "name": "latitude", "optional": false, "control": "field", "type": "string", "hint": { "en_US": "Input latitude", "zh_CN": "输入经度" }, "label": { "en_US": "Latitude", "zh_CN": "经度" } }, { "name": "longitude", "optional": false, "control": "field", "type": "string", "hint": { "en_US": "Input longitude", "zh_CN": "输入纬度" }, "label": { "en_US": "Longitude", "zh_CN": "输入纬度" } } ], "return": { "type": "int", "hint": { "en_US": "Encoded value", "zh_CN": "编码值" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash Encode to Integer", "zh_CN": "Geohash 整数编码" } } }, { "name": "geohashDecode", "example": "geohashDecode(hash )", "hint": { "en_US": "Decode characters into latitude and longitude", "zh_CN": "将字符解码为经纬度" }, "args": [ { "name": "data", "hidden": false, "optional": false, "control": "field", "type": "string", "hint": { "en_US": "Input data", "zh_CN": "输入数据" }, "label": { "en_US": "Field", "zh_CN": "输入数据" } } ], "return": { "type": "struct", "hint": { "en_US": "Decoded Value", "zh_CN": "解码值" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash Decode", "zh_CN": "Geohash 解码" } } }, { "name": "geohashDecodeInt", "example": "geohashDecodeInt(hash)", "hint": { "en_US": "Decode numbers into latitude and longitude", "zh_CN": "将数字解码为经纬度" }, "args": [ { "name": "data", "hidden": false, "optional": false, "control": "field", "type": "number", "hint": { "en_US": "Input data", "zh_CN": "输入数据" }, "label": { "en_US": "Data", "zh_CN": "输入数据" } } ], "return": { "type": "struct", "hint": { "en_US": "Decoded Value", "zh_CN": "解码值" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash Decode Integer", "zh_CN": "Geohash 整数解码" } } }, { "name": "geohashBoundingBox", "example": "geohashBoundingBox(hash )", "hint": { "en_US": "Area for calculating character codes", "zh_CN": "计算字符编码的区域" }, "args": [ { "name": "data", "hidden": false, "optional": false, "control": "text", "type": "string", "hint": { "en_US": "Input data", "zh_CN": "输入数据" }, "label": { "en_US": "Data", "zh_CN": "输入数据" } } ], "return": { "type": "struct", "hint": { "en_US": "Box", "zh_CN": "区域" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash Bounding Box", "zh_CN": "Geohash 边界框" } } }, { "name": "geohashBoundingBoxInt", "example": "geohashBoundingBoxInt(hash)", "hint": { "en_US": "Calculate the area of digital coding", "zh_CN": "计算数字编码的区域" }, "args": [ { "name": "data", "hidden": false, "optional": false, "control": "field", "type": "string", "hint": { "en_US": "Input data", "zh_CN": "输入数据" }, "label": { "en_US": "Data", "zh_CN": "输入数据" } } ], "return": { "type": "int", "hint": { "en_US": "Bounding Box", "zh_CN": "区域编码" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash Integer Bounding Box", "zh_CN": "Geohash 整数边界框" } } }, { "name": "geohashNeighbor", "example": "geohashNeighbor(hash,direction )", "hint": { "en_US": "Calculate the neighbor of the corresponding direction of the character encoding", "zh_CN": "计算字符编码对应方向的邻居" }, "args": [ { "name": "hash", "hidden": false, "optional": false, "control": "field", "type": "string", "hint": { "en_US": "Input data", "zh_CN": "输入数据" }, "label": { "en_US": "Field", "zh_CN": "输入数据" } }, { "name": "direction", "optional": false, "control": "text", "type": "string", "hint": { "en_US": "Input direction", "zh_CN": "输入方向" }, "label": { "en_US": "Direction", "zh_CN": "方向" } } ], "return": { "type": "string", "hint": { "en_US": "Neighbor", "zh_CN": "相邻位置" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash Neighbor", "zh_CN": "Geohash 相邻位置" } } }, { "name": "geohashNeighborInt", "example": "geohashNeighborInt(hash,direction )", "hint": { "en_US": "Calculate the neighbors in the corresponding direction of the digital code", "zh_CN": "计算数字编码对应方向的邻居" }, "args": [ { "name": "hash", "hidden": false, "optional": false, "control": "field", "type": "string", "hint": { "en_US": "Input data", "zh_CN": "输入数据" }, "label": { "en_US": "Data", "zh_CN": "输入数据" } }, { "name": "direction", "optional": false, "control": "text", "type": "string", "hint": { "en_US": "Input direction", "zh_CN": "输入方向" }, "label": { "en_US": "Direction", "zh_CN": "方向" } } ], "return": { "type": "string", "hint": { "en_US": "Neighbor", "zh_CN": "相邻位置编码" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash Neighbor Integer", "zh_CN": "Geohash 相邻位置编码" } } }, { "name": "geohashNeighbors", "example": "geohashNeighbors(hash)", "hint": { "en_US": "Calculate all neighbors of character encoding", "zh_CN": "计算字符编码的所有邻居" }, "args": [ { "name": "hash", "hidden": false, "optional": false, "control": "field", "type": "string", "hint": { "en_US": "Input data", "zh_CN": "输入数据" }, "label": { "en_US": "Field", "zh_CN": "输入数据" } } ], "return": { "type": "array", "hint": { "en_US": "All Neighbor", "zh_CN": "所有相邻位置" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash All Neighbors", "zh_CN": "Geohash 所有相邻位置" } } }, { "name": "geohashNeighborsInt", "example": "geohashNeighborsInt(hash)", "hint": { "en_US": "Calculate all neighbors of digital encoding", "zh_CN": "计算数字编码的所有邻居" }, "args": [{ "name": "hash", "hidden": false, "optional": false, "control": "text", "type": "string", "hint": { "en_US": "Input data", "zh_CN": "输入数据" }, "label": { "en_US": "Field", "zh_CN": "输入数据" } } ], "return": { "type": "array", "hint": { "en_US": "All Neighbor", "zh_CN": "所有相邻位置编码" } }, "node": { "category": "function", "icon": "iconPath", "label": { "en_US": "Geohash All Neighbors Integer", "zh_CN": "Geohash 所有相邻位置编码" } } }] }