public function createImpression($sourceId, $targetId) { try { $newImpressionTO = new ImpressionTO(); $newImpressionTO->setSourceId($sourceId); $newImpressionTO->setTargetId($targetId); $this->provider->storeImpressionTO($newImpressionTO); return $newImpressionTO; } catch (EyePeopleException $e) { throw new EyePeopleException('Unable to create the impression with target ' . $targetId . ' and source ' . $sourceId); } }
public function getAllTagPerImpressionTO(ImpressionTO $impressionTO) { try { return $this->provider->retrieveAllTagPerImpressionTO($impressionTO->getId()); } catch (EyePeopleException $e) { throw new EyePeopleException('Unable to remove the tag ' . $tag->getName()); } }