public function SegmenterInterface::getSegmentedData

Add the segmented data tag to the data or update it.

Will just segment an item if it has the key '#translate' set to TRUE.

Parameters

array $data: The data array of a JobItem. Example: [ '#text' => 'Unsegmented source text', '#translate' => TRUE, ]

Return value

array An array with the the segments. Example: [ '#text' => 'Unsegmented source text', '#translate' => TRUE, '#segmented_text' => '<tmgmt-segment>Segmented source text</tmgmt-segment>' ]

1 method overrides SegmenterInterface::getSegmentedData()
NullSegmenter::getSegmentedData in src/NullSegmenter.php
Add the segmented data tag to the data or update it.

File

src/SegmenterInterface.php, line 73

Class

SegmenterInterface
This interface offers a suite of methods to add segments and filter data.

Namespace

Drupal\tmgmt

Code

public function getSegmentedData($data);