You are here

TextFieldHandler.php in CRM Core 8.3

File

modules/crm_core_match/src/Plugin/crm_core_match/field/TextFieldHandler.php
View source
<?php

namespace Drupal\crm_core_match\Plugin\crm_core_match\field;

use Drupal\Core\StringTranslation\StringTranslationTrait;

/**
 * Class for evaluating text fields.
 *
 * @CrmCoreMatchFieldHandler (
 *   id = "text"
 * )
 */
class TextFieldHandler extends FieldHandlerBase {
  use StringTranslationTrait;

  /**
   * {@inheritdoc}
   */
  public function getOperators($property = 'value') {
    return [
      '=' => $this
        ->t('Equals'),
      'STARTS_WITH' => $this
        ->t('Starts with'),
      'ENDS_WITH' => $this
        ->t('Ends with'),
      'CONTAINS' => $this
        ->t('Contains'),
    ];
  }

}

Classes

Namesort descending Description
TextFieldHandler Class for evaluating text fields.