search_api-8.x-1.15/src/Event/MappingFieldTypesEvent.php
src/Event/MappingFieldTypesEvent.php
<?php
namespace Drupal\search_api\Event;
use Symfony\Component\EventDispatcher\Event;
/**
* Wraps a field types mapped event.
*/
final class MappingFieldTypesEvent extends Event {
/**
* Reference to the field type mapping.
*
* @var array
*/
protected $fieldTypeMapping;
/**
* Constructs a new class instance.
*
* @param array $fieldTypeMapping
* Reference to the field type mapping.
*/
public function __construct(array &$fieldTypeMapping) {
$this->fieldTypeMapping = &$fieldTypeMapping;
}
/**
* Retrieves a reference to the field type mapping.
*
* @return array
* An array mapping all known (and supported) Drupal data types to their
* corresponding Search API data types. A value of FALSE means that fields
* of that type should be ignored by the Search API.
*/
public function &getFieldTypeMapping() {
return $this->fieldTypeMapping;
}
}
