function openlayers_ui_get_style_plugins_for_property in Openlayers 6.2
Get a list of style plugins providing handling of a given property
Parameters
$property_name Name of the property we're interested in:
1 call to openlayers_ui_get_style_plugins_for_property()
- openlayers_ui_styles_form in modules/
openlayers_ui/ includes/ openlayers_ui.styles.inc - Styles add/edit form.
File
- modules/
openlayers_ui/ includes/ openlayers_ui.styles.inc, line 456 - This file holds the functions handling styles in the Openlayers UI.
Code
function openlayers_ui_get_style_plugins_for_property($property_name) {
$handling = array();
$available = openlayers_style_plugins();
foreach ($available as $plugname => $plugin) {
$plugin_class = ctools_plugin_get_class($plugin, 'style_plugin');
if (empty($plugin_class)) {
continue;
}
// should we watchdog here ?
$plugin_instance = new $plugin_class();
if ($plugin_instance
->can_handle_property($property_name)) {
$handling[$plugname] = $plugin;
}
}
return $handling;
}