Function help improvements

This commit is contained in:
Matthias Kuhn 2018-12-18 14:54:35 +01:00
parent 7a8939442f
commit 2b5830ec9c
No known key found for this signature in database
GPG Key ID: 7A7F1A1C90C3E6A7

View File

@ -3,10 +3,10 @@
"type": "function",
"description": "Takes a layer and decodes the uri of the underlying data provider. It depends on the dataprovider, which data is available.",
"arguments": [ {"arg":"layer","description":"The layer for which the uri should be decoded."},
{"arg":"part","description":"The part of the uri to return. If unspecified, a map with all uri parts will be returned."} ],
{"arg":"part","description":"The part of the uri to return. If unspecified, a map with all uri parts will be returned.","optional":true} ],
"examples": [ { "expression":"decode_uri(@layer)", "returns":"{'layerId': '0', 'layerName': '', 'path': '/home/qgis/shapefile.shp'}"},
{ "expression":"decode_uri(@layer)", "returns":"{'layerId': NULL, 'layerName': 'layer', 'path': '/home/qgis/geopackage.gpkg'}"},
{ "expression":"decode_uri(@layer), 'path'", "returns":"'C:\my_data\qgis\shape.shp'"}
{ "expression":"decode_uri(@layer, 'path')", "returns":"'C:\my_data\qgis\shape.shp'"}
]
}