/**
* Get an ID for the given data
*
* @return string
*/
public function getId()
{
$values = [];
foreach ($this->metadata->getIdColumns() as $column) {
$values[] = $this->getPropertyValue($column->getProperty());
}
if (!count($values)) {
throw new InvalidEntityException('Entity "' . $this->metadata->getClassName() . '" has no ID column');
}
return implode(self::ID_DELIMITER, $values);
}