Converts a flattened data structure into a nested array.
This function can be used by translators to help with the data conversion.
Nested keys will be created based on the colon, so for example $flattened_data['key1][key2][key3'] will be converted into $data['key1']['key2']['key3'].
array $flattened_data: The flattened data array.
array The nested data array.
public function unflatten(array $flattened_data) {
$data = array();
foreach ($flattened_data as $key => $flattened_data_entry) {
NestedArray::setValue($data, explode(static::TMGMT_ARRAY_DELIMITER, $key), $flattened_data_entry);
}
return $data;
}