You are here

public static function Openlayers::loadAll in Openlayers 7.3

Load all objects.

Parameters

string $object_type: Type of object to load: map|layer|source|control|interaction|style|component.

Return value

\Drupal\openlayers\Types\ObjectInterface[] The array of objects.

13 calls to Openlayers::loadAll()
Base::getParents in src/Types/Base.php
Returns an array with the maps this object is attached on.
Group::optionsForm in src/Plugin/Layer/Group/Group.php
@TODO What is this return? If it is the form, why is form by reference?
openlayers_block_block_info in modules/openlayers_block/openlayers_block.module
Implements hook_block_info().
openlayers_field_field_formatter_settings_form in modules/openlayers_field/openlayers_field.module
Implements hook_field_formatter_settings_form().
openlayers_geofield_field_formatter_settings_form in modules/openlayers_geofield/openlayers_geofield.module
Implements hook_field_formatter_settings_form().

... See full list

File

src/Openlayers.php, line 83
Contains Openlayers.

Class

Openlayers
Class Openlayers.

Namespace

Drupal\openlayers

Code

public static function loadAll($object_type = NULL) {
  $objects = array();
  foreach (Openlayers::loadAllExportable($object_type) as $exportable) {
    if (is_object($exportable)) {
      $objects[$exportable->machine_name] = Openlayers::load($object_type, $exportable);
    }
  }
  return $objects;
}