/**
  * @since 2.4
  *
  * @return array
  */
 public function getErrors()
 {
     return $this->dataValue->getErrors();
 }
 /**
  * @since 2.5
  *
  * @param DataValue $dataValue
  *
  * @return DIContainer|null
  */
 public function getErrorContainerFromDataValue(DataValue $dataValue)
 {
     if ($dataValue->getErrors() === array()) {
         return null;
     }
     $property = $dataValue->getProperty();
     $hash = '';
     if ($property !== null) {
         $hash = $property->getKey();
     }
     $containerSemanticData = $this->newContainerSemanticData($hash);
     foreach ($dataValue->getErrors() as $error) {
         $this->addToContainerSemanticData($containerSemanticData, $property, Message::encode($error));
     }
     return new DIContainer($containerSemanticData);
 }