Static
getReturns the featureType name out of a given feature. It assumes that the feature has an ID in the following structure FEATURETYPE.FEATUREID.
The feature to obtain the featureType name from.
The (unqualified) name of the featureType or undefined if the name could not be picked.
Static
getExtracts the featureType name from given GetFeatureInfo URL. This method is mostly useful for raster layers which features could have no ID set.
GetFeatureInfo URL possibly containing featureType name.
Whether the qualified featureType name should be returned or not. Default is true.
Obtained featureType name as string.
Static
mapMaps an array of features to an array of geometries.
The geometries of the features
Static
resolveResolves the given template string with the given feature attributes, e.g. the template "Size of area is {{AREA_SIZE}} km²" would be to resolved to "Size of area is 1909 km²" (assuming the feature's attribute AREA_SIZE really exists).
The feature to get the attributes from.
The template string to resolve.
Optional
noValueFoundText: string = 'n.v.'The text to apply, if the templated value could not be found, default is to 'n.v.'.
Optional
valueAdjust: (key: string, val: any) => any = ...A method that will be called with each key/value match, we'll use what this function returns for the actual replacement. Optional, defaults to a function which will return the raw value it received. This can be used for last minute adjustments before replacing happens, e.g. to filter out falsy values or to do number formatting and such.
If set to true, template won't be wrapped into -tag and will be returned as URL. Default is false.
The resolved template string.
Helper class for working with OpenLayers features.
FeatureUtil