public function setEntityManager(EntityManagerInterface $em)
    {
        $this->em = $em;
        // Because these repositories are shared between the different functions it's
        // easier to make them available in the class.
        $this->pagePartRepo = $em->getRepository('KunstmaanPagePartBundle:PagePartRef');
        $this->translationRepo = $em->getRepository('KunstmaanNodeBundle:NodeTranslation');
        $this->nodeRepo = $em->getRepository('KunstmaanNodeBundle:Node');
    }