public function rewriteIds($idMapping) { if ($this->type == "asset" && array_key_exists("asset", $idMapping) and array_key_exists($this->getId(), $idMapping["asset"])) { $this->setId($idMapping["asset"][$this->getId()]); } }