Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #46502 from elpaso/formatted_attributes
New represent_attributes function
- Loading branch information
Showing
3 changed files
with
183 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"name": "represent_attributes", | ||
"type": "function", | ||
"groups": ["Record and Attributes"], | ||
"description": "Returns a map with the attribute names as keys and the configured representation values as values. The representation value for the attributes depends on the configured widget type for each attribute. Can be used with zero, one or more arguments, see below for details.", | ||
"variants": [ | ||
{ | ||
"variant": "No parameters", | ||
"variant_description": "If called with no parameters, the function will return the representation of the attributes of the current feature in the current layer.", | ||
"arguments": [], | ||
"examples": [ { "expression": "represent_attributes()", "returns" : "The representation of the attributes for the current feature." } ] | ||
}, | ||
{ | ||
"variant": "One 'feature' parameter", | ||
"variant_description": "If called with a 'feature' parameter only, the function will return the representation of the attributes of the specified feature from the current layer.", | ||
"arguments": [ { "arg": "feature", "description": "The feature which should be evaluated." } ], | ||
"examples": [ { "expression": "represent_attributes(@atlas_feature)", "returns" : "The representation of the attributes for the specified feature from the current layer." } ] | ||
}, | ||
{ | ||
"variant": "Layer and feature parameters", | ||
"variant_description": "If called with a 'layer' and a 'feature' parameter, the function will return the representation of the attributes of the specified feature from the specified layer.", | ||
"arguments": [ { "arg": "layer", "description": "The layer (or its ID or name)." }, { "arg": "feature", "description": "The feature which should be evaluated." } ], | ||
"examples": [ { "expression": "represent_attributes('atlas_layer', @atlas_feature)", "returns" : "The representation of the attributes for the specified feature from the specified layer." } ] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters