/**
  * get the tree of the page
  *
  * @return array of Application\Sonata\PageBundle\Entity\Page
  */
 public function getParents()
 {
     if (!$this->parents) {
         $parents = array();
         $snapshot = $this->snapshot;
         while ($snapshot) {
             $content = json_decode($snapshot->getContent(), true);
             $parentId = $content['parent_id'];
             $snapshot = $parentId ? $this->manager->getSnapshotByPageId($parentId) : null;
             if ($snapshot) {
                 $parents[] = new SnapshotPageProxy($this->manager, $snapshot);
             }
         }
         $this->setParents(array_reverse($parents));
     }
     return $this->parents;
 }