public function createChildControls()
{
$this->_creatingChildren = true;
$result = true;
try {
$result = $this->getTemplateControl()->evaluateExpression($this->_condition);
} catch (\Exception $e) {
throw new TInvalidDataValueException('conditional_condition_invalid', $this->_condition, $e->getMessage());
}
if ($result) {
if ($this->_trueTemplate) {
$this->_trueTemplate->instantiateIn($this->getTemplateControl(), $this);
}
} else {
if ($this->_falseTemplate) {
$this->_falseTemplate->instantiateIn($this->getTemplateControl(), $this);
}
}
$this->_creatingChildren = false;
}