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

Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter Class Reference
Inheritance diagram for eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter:

## Public Member Functions
| __construct (LanguageService $languageService)
| toStorageValue (FieldValue $value, StorageFieldValue $storageFieldValue)
| Converts data from $value to $storageFieldValue. More...
| toFieldValue (StorageFieldValue $value, FieldValue $fieldValue)
| Converts data from $value to $fieldValue. More...
| toStorageFieldDefinition (FieldDefinition $fieldDef, StorageFieldDefinition $storageDef)
| Converts field definition data in $fieldDef into $storageFieldDef. More...
| toFieldDefinition (StorageFieldDefinition $storageDef, FieldDefinition $fieldDef)
| Converts field definition data in $storageDef into $fieldDef. More...
| getIndexColumn ()
| Returns the name of the index column in the attribute table. More...

## Static Public Member Functions
static | create ()
| Factory for current class. More...

## Private Member Functions
| buildOptionsXml (array $selectionOptions)

## Private Attributes
| $languageService

## Detailed Description

Definition at line 18 of file SelectionConverter.php.

## Constructor & Destructor Documentation

## ◆ __construct()

eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter::__construct | ( | LanguageService | $languageService | ) |

Parameters

  \eZ\Publish\API\Repository\LanguageService | $languageService |

Definition at line 26 of file SelectionConverter.php.

References eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter\$languageService.

## Member Function Documentation

## ◆ buildOptionsXml()

eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter::buildOptionsXml | ( | array | $selectionOptions | ) |
| private

Parameters

  string[] | $selectionOptions |

Returns
  \DOMDocument

Definition at line 175 of file SelectionConverter.php.

Referenced by eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter\toStorageFieldDefinition().

## ◆ create()

static eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter::create | ( |  | ) |
| static

Factory for current class.

Note: Class should instead be configured as service if it gains dependencies.

Deprecated:
  since 6.8, will be removed in 7.x, use default constructor instead.

Returns
  \eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter

Definition at line 41 of file SelectionConverter.php.

## ◆ getIndexColumn()

eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter::getIndexColumn | ( |  | ) |

Returns the name of the index column in the attribute table.

Returns the name of the index column the datatype uses, which is either "sort_key_int" or "sort_key_string". This column is then used for filtering and sorting for this type.

Returns
  string

Implements eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter.

Definition at line 165 of file SelectionConverter.php.

## ◆ toFieldDefinition()

eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter::toFieldDefinition | ( | StorageFieldDefinition | $storageDef,
|  | FieldDefinition | $fieldDef
| ) |  |

Converts field definition data in $storageDef into $fieldDef.

Parameters

  \eZ\Publish\Core\Persistence\Legacy\Content\StorageFieldDefinition | $storageDef |
  \eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition | $fieldDef |

Implements eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter.

Definition at line 116 of file SelectionConverter.php.

## ◆ toFieldValue()

eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter::toFieldValue | ( | StorageFieldValue | $value,
|  | FieldValue | $fieldValue
| ) |  |

Converts data from $value to $fieldValue.

Parameters

  \eZ\Publish\Core\Persistence\Legacy\Content\StorageFieldValue | $value |
  \eZ\Publish\SPI\Persistence\Content\FieldValue | $fieldValue |

Implements eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter.

Definition at line 63 of file SelectionConverter.php.

## ◆ toStorageFieldDefinition()

eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter::toStorageFieldDefinition | ( | FieldDefinition | $fieldDef,
|  | StorageFieldDefinition | $storageDef
| ) |  |

Converts field definition data in $fieldDef into $storageFieldDef.

Parameters

  \eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition | $fieldDef |
  \eZ\Publish\Core\Persistence\Legacy\Content\StorageFieldDefinition | $storageDef |

Implements eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter.

Definition at line 82 of file SelectionConverter.php.

References eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter\buildOptionsXml().

## ◆ toStorageValue()

eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter::toStorageValue | ( | FieldValue | $value,
|  | StorageFieldValue | $storageFieldValue
| ) |  |

Converts data from $value to $storageFieldValue.

Parameters

  \eZ\Publish\SPI\Persistence\Content\FieldValue | $value |
  \eZ\Publish\Core\Persistence\Legacy\Content\StorageFieldValue | $storageFieldValue |

Implements eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter.

Definition at line 52 of file SelectionConverter.php.

## Member Data Documentation

## ◆ $languageService

eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter::$languageService
| private

Definition at line 21 of file SelectionConverter.php.

Referenced by eZ\Publish\Core\Persistence\Legacy\Content\FieldValue\Converter\SelectionConverter\__construct().

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

- SelectionConverter.php

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