Files
cdesai-tff/src/SlugifyServiceInterface.php
T
2021-02-18 07:50:05 +00:00

28 lines
605 B
PHP

<?php
namespace Drupal\cdesai_tff;
use Drupal\Core\Field\FieldItemInterface;
interface SlugifyServiceInterface {
const CONFIG_NAME = 'cdesai_tff.settings';
const DEFAULT_SEPARATOR = '_';
/**
* Converts the given item to slug format.
*
* @param \Drupal\Core\Field\FieldItemInterface $item
* Field item object that needs to be converted.
*
* @param string|null $separator (optional)
* Separator to use for slug. Defaults to '_'.
*
* @return string
* The converted string.
*/
public function convertToSlug(FieldItemInterface $item, $separator = NULL);
}