You are here

final class MappingFieldTypesEvent in Search API 8

Wraps a field types mapped event.

Hierarchy

Expanded class hierarchy of MappingFieldTypesEvent

2 files declare their use of MappingFieldTypesEvent
DataTypeHelper.php in src/Utility/DataTypeHelper.php
EventListener.php in tests/search_api_test_events/src/EventListener.php

File

src/Event/MappingFieldTypesEvent.php, line 10

Namespace

Drupal\search_api\Event
View source
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;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
MappingFieldTypesEvent::$fieldTypeMapping protected property Reference to the field type mapping.
MappingFieldTypesEvent::getFieldTypeMapping public function Retrieves a reference to the field type mapping.
MappingFieldTypesEvent::__construct public function Constructs a new class instance.