You are here

function openlayers_layer_type::__construct in Openlayers 6.2

Same name and namespace in other branches
  1. 7.2 openlayers.module \openlayers_layer_type::__construct()
10 calls to openlayers_layer_type::__construct()
openlayers_layer_type_cloudmade::__construct in includes/layer_types/cloudmade.inc
openlayers_layer_type_google::__construct in includes/layer_types/google.inc
openlayers_layer_type_kml::__construct in includes/layer_types/kml.inc
openlayers_layer_type_maptiler::__construct in includes/layer_types/maptiler.inc
openlayers_layer_type_osm::__construct in includes/layer_types/osm.inc

... See full list

10 methods override openlayers_layer_type::__construct()
openlayers_layer_type_cloudmade::__construct in includes/layer_types/cloudmade.inc
openlayers_layer_type_google::__construct in includes/layer_types/google.inc
openlayers_layer_type_kml::__construct in includes/layer_types/kml.inc
openlayers_layer_type_maptiler::__construct in includes/layer_types/maptiler.inc
openlayers_layer_type_osm::__construct in includes/layer_types/osm.inc

... See full list

File

./openlayers.module, line 893
Main OpenLayers API File

Class

openlayers_layer_type
We define base classes in the core module. All other parent classes can be autoloaded through ctools.

Code

function __construct($layer = array(), $map = array()) {
  foreach (array(
    'name',
    'title',
    'description',
    'data',
    'export_type',
  ) as $k) {
    if (isset($layer->{$k})) {
      $this->{$k} = $layer->{$k};
    }
  }
  if (isset($this->data) && is_array($this->data)) {
    $this->data += $this
      ->options_init();
  }
  $this->map = $map;
}