Exponential 5.x Kernel 7.5.40 Exponential New Stack (Symfony-based) Kernel — PHP Class Reference

Public Member Functions | Private Member Functions | List of all members
eZ\Publish\Core\FieldType\TextBlock\SearchField Class Reference

Indexable definition for TextBlock field type. More...

Inheritance diagram for eZ\Publish\Core\FieldType\TextBlock\SearchField:

## Public Member Functions
| getIndexData (Field $field, FieldDefinition $fieldDefinition)
| Get index data for field for search backend. More...
| getIndexDefinition ()
| Get index field types for search backend. More...
| getDefaultMatchField ()
| Get name of the default field to be used for matching. More...
| getDefaultSortField ()
| Get name of the default field to be used for sorting. More...
Public Member Functions inherited from eZ\Publish\SPI\FieldType\Indexable
| getIndexData (Field $field, FieldDefinition $fieldDefinition)
| Get index data for field for search backend. More...

## Private Member Functions
| extractShortText ($string)
| Extracts short snippet of the given $string. More...

## Detailed Description

Indexable definition for TextBlock field type.

Definition at line 17 of file TextBlock/SearchField.php.

## Member Function Documentation

## ◆ extractShortText()

eZ\Publish\Core\FieldType\TextBlock\SearchField::extractShortText | ( |  | $string | ) |
| private

Extracts short snippet of the given $string.

Parameters

  string | $string |

Returns
  string

Definition at line 50 of file TextBlock/SearchField.php.

Referenced by eZ\Publish\Core\FieldType\TextBlock\SearchField\getIndexData().

## ◆ getDefaultMatchField()

eZ\Publish\Core\FieldType\TextBlock\SearchField::getDefaultMatchField | ( |  | ) |

Get name of the default field to be used for matching.

As field types can index multiple fields (see MapLocation field type's implementation of this interface), this method is used to define default field for matching. Default field is typically used by Field criterion.

Returns
  string

Implements eZ\Publish\SPI\FieldType\Indexable.

Definition at line 76 of file TextBlock/SearchField.php.

Referenced by eZ\Publish\Core\FieldType\TextBlock\SearchField\getDefaultSortField().

## ◆ getDefaultSortField()

eZ\Publish\Core\FieldType\TextBlock\SearchField::getDefaultSortField | ( |  | ) |

Get name of the default field to be used for sorting.

As field types can index multiple fields (see MapLocation field type's implementation of this interface), this method is used to define default field for sorting. Default field is typically used by Field sort clause.

Returns
  string

Implements eZ\Publish\SPI\FieldType\Indexable.

Definition at line 90 of file TextBlock/SearchField.php.

References eZ\Publish\Core\FieldType\TextBlock\SearchField\getDefaultMatchField().

## ◆ getIndexData()

eZ\Publish\Core\FieldType\TextBlock\SearchField::getIndexData | ( | Field | $field,
|  | FieldDefinition | $fieldDefinition
| ) |  |

Get index data for field for search backend.

Parameters

  \eZ\Publish\SPI\Persistence\Content\Field | $field |
  \eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition | $fieldDefinition |

Returns
  \eZ\Publish\SPI\Search\Field[]

Definition at line 27 of file TextBlock/SearchField.php.

References eZ\Publish\Core\FieldType\TextBlock\SearchField\extractShortText().

## ◆ getIndexDefinition()

eZ\Publish\Core\FieldType\TextBlock\SearchField::getIndexDefinition | ( |  | ) |

Get index field types for search backend.

Returns
  \eZ\Publish\SPI\Search\FieldType[]

Implements eZ\Publish\SPI\FieldType\Indexable.

Definition at line 60 of file TextBlock/SearchField.php.

The documentation for this class was generated from the following file:

- TextBlock/SearchField.php

Copyright © 1998 – 2026 7x. All rights reserved. Licensed under the GNU GPLv2+.