CodeExplorer EmotionTemplate example
// assign attribute
if (!
empty($data['__emotionAttribute_id'
])) { $this->attributeHydrator->
addAttribute($emotion,
$data, 'emotionAttribute'
);
} return $emotion;
} private function assignTemplate(Emotion
$emotion, array
$data): void
{ $template =
new EmotionTemplate();
$template->
setId((int) $data['__emotionTemplate_id'
]);
$template->
setName($data['__emotionTemplate_name'
]);
$template->
setFile($data['__emotionTemplate_file'
]);
$emotion->
setTemplate($template);
} private function createDate(?string
$dateString): ?DateTimeInterface
{ if (!\
is_string($dateString)) {