You are here

public function GeolocationGeometryDataManager::getGemeotryDataBatch in Geolocation Field 8.3

Return GeolocationGeometryData by ID.

Parameters

string $id: GeolocationGeometryData ID.

Return value

array|false GeolocationGeometryData or FALSE.

File

modules/geolocation_geometry/modules/geolocation_geometry_data/src/GeolocationGeometryDataManager.php, line 40

Class

GeolocationGeometryDataManager
Search plugin manager.

Namespace

Drupal\geolocation_geometry_data

Code

public function getGemeotryDataBatch($id) {
  $definitions = $this
    ->getDefinitions();
  if (empty($definitions[$id])) {
    return FALSE;
  }
  try {
    $instance = $this
      ->createInstance($id);
    if ($instance) {
      return $instance
        ->getBatch();
    }
  } catch (\Exception $e) {
    return FALSE;
  }
  return FALSE;
}