<?php

namespace Proxies\__CG__\Fishman\PollBundle\Entity;

/**
 * THIS CLASS WAS GENERATED BY THE DOCTRINE ORM. DO NOT EDIT THIS FILE.
 */
class Poll extends \Fishman\PollBundle\Entity\Poll implements \Doctrine\ORM\Proxy\Proxy
{
    private $_entityPersister;
    private $_identifier;
    public $__isInitialized__ = false;
    public function __construct($entityPersister, $identifier)
    {
        $this->_entityPersister = $entityPersister;
        $this->_identifier = $identifier;
    }
    /** @private */
    public function __load()
    {
        if (!$this->__isInitialized__ && $this->_entityPersister) {
            $this->__isInitialized__ = true;

            if (method_exists($this, "__wakeup")) {
                // call this after __isInitialized__to avoid infinite recursion
                // but before loading to emulate what ClassMetadata::newInstance()
                // provides.
                $this->__wakeup();
            }

            if ($this->_entityPersister->load($this->_identifier, $this) === null) {
                throw new \Doctrine\ORM\EntityNotFoundException();
            }
            unset($this->_entityPersister, $this->_identifier);
        }
    }

    /** @private */
    public function __isInitialized()
    {
        return $this->__isInitialized__;
    }

    
    public function getId()
    {
        if ($this->__isInitialized__ === false) {
            return (int) $this->_identifier["id"];
        }
        $this->__load();
        return parent::getId();
    }

    public function resetId()
    {
        $this->__load();
        return parent::resetId();
    }

    public function setTitle($title)
    {
        $this->__load();
        return parent::setTitle($title);
    }

    public function getTitle()
    {
        $this->__load();
        return parent::getTitle();
    }

    public function setVersion($version)
    {
        $this->__load();
        return parent::setVersion($version);
    }

    public function getVersion()
    {
        $this->__load();
        return parent::getVersion();
    }

    public function setDescription($description)
    {
        $this->__load();
        return parent::setDescription($description);
    }

    public function getDescription()
    {
        $this->__load();
        return parent::getDescription();
    }

    public function setType($type)
    {
        $this->__load();
        return parent::setType($type);
    }

    public function getType()
    {
        $this->__load();
        return parent::getType();
    }

    public function setLevel($level)
    {
        $this->__load();
        return parent::setLevel($level);
    }

    public function getLevel()
    {
        $this->__load();
        return parent::getLevel();
    }

    public function setAlignment($alignment)
    {
        $this->__load();
        return parent::setAlignment($alignment);
    }

    public function getAlignment()
    {
        $this->__load();
        return parent::getAlignment();
    }

    public function setSequenceQuestion($sequenceQuestion)
    {
        $this->__load();
        return parent::setSequenceQuestion($sequenceQuestion);
    }

    public function getSequenceQuestion()
    {
        $this->__load();
        return parent::getSequenceQuestion();
    }

    public function setDivide($divide)
    {
        $this->__load();
        return parent::setDivide($divide);
    }

    public function getDivide()
    {
        $this->__load();
        return parent::getDivide();
    }

    public function setNumberQuestion($numberQuestion)
    {
        $this->__load();
        return parent::setNumberQuestion($numberQuestion);
    }

    public function getNumberQuestion()
    {
        $this->__load();
        return parent::getNumberQuestion();
    }

    public function setDuration($duration)
    {
        $this->__load();
        return parent::setDuration($duration);
    }

    public function getDuration()
    {
        $this->__load();
        return parent::getDuration();
    }

    public function setPeriod($period)
    {
        $this->__load();
        return parent::setPeriod($period);
    }

    public function getPeriod()
    {
        $this->__load();
        return parent::getPeriod();
    }

    public function setStatus($status)
    {
        $this->__load();
        return parent::setStatus($status);
    }

    public function getStatus()
    {
        $this->__load();
        return parent::getStatus();
    }

    public function setCurrentVersion($currentVersion)
    {
        $this->__load();
        return parent::setCurrentVersion($currentVersion);
    }

    public function getCurrentVersion()
    {
        $this->__load();
        return parent::getCurrentVersion();
    }

    public function setOriginalId($originalId)
    {
        $this->__load();
        return parent::setOriginalId($originalId);
    }

    public function getOriginalId()
    {
        $this->__load();
        return parent::getOriginalId();
    }

    public function setCreated($created)
    {
        $this->__load();
        return parent::setCreated($created);
    }

    public function getCreated()
    {
        $this->__load();
        return parent::getCreated();
    }

    public function setChanged($changed)
    {
        $this->__load();
        return parent::setChanged($changed);
    }

    public function getChanged()
    {
        $this->__load();
        return parent::getChanged();
    }

    public function setCreatedBy($createdBy)
    {
        $this->__load();
        return parent::setCreatedBy($createdBy);
    }

    public function getCreatedBy()
    {
        $this->__load();
        return parent::getCreatedBy();
    }

    public function setModifiedBy($modifiedBy)
    {
        $this->__load();
        return parent::setModifiedBy($modifiedBy);
    }

    public function getModifiedBy()
    {
        $this->__load();
        return parent::getModifiedBy();
    }

    public function setCategory(\Fishman\EntityBundle\Entity\Category $category = NULL)
    {
        $this->__load();
        return parent::setCategory($category);
    }

    public function getCategory()
    {
        $this->__load();
        return parent::getCategory();
    }

    public function addPollsection(\Fishman\PollBundle\Entity\Pollsection $pollsections)
    {
        $this->__load();
        return parent::addPollsection($pollsections);
    }

    public function removePollsection(\Fishman\PollBundle\Entity\Pollsection $pollsections)
    {
        $this->__load();
        return parent::removePollsection($pollsections);
    }

    public function getPollsections()
    {
        $this->__load();
        return parent::getPollsections();
    }

    public function __toString()
    {
        $this->__load();
        return parent::__toString();
    }

    public function addPollquestion(\Fishman\PollBundle\Entity\Pollquestion $pollquestions)
    {
        $this->__load();
        return parent::addPollquestion($pollquestions);
    }

    public function removePollquestion(\Fishman\PollBundle\Entity\Pollquestion $pollquestions)
    {
        $this->__load();
        return parent::removePollquestion($pollquestions);
    }

    public function getPollquestions()
    {
        $this->__load();
        return parent::getPollquestions();
    }

    public function addPollscheduling(\Fishman\PollBundle\Entity\Pollscheduling $pollschedulings)
    {
        $this->__load();
        return parent::addPollscheduling($pollschedulings);
    }

    public function removePollscheduling(\Fishman\PollBundle\Entity\Pollscheduling $pollschedulings)
    {
        $this->__load();
        return parent::removePollscheduling($pollschedulings);
    }

    public function getPollschedulings()
    {
        $this->__load();
        return parent::getPollschedulings();
    }

    public function addEntitypoll(\Fishman\PollBundle\Entity\Entitypoll $entitypolls)
    {
        $this->__load();
        return parent::addEntitypoll($entitypolls);
    }

    public function removeEntitypoll(\Fishman\PollBundle\Entity\Entitypoll $entitypolls)
    {
        $this->__load();
        return parent::removeEntitypoll($entitypolls);
    }

    public function getEntitypolls()
    {
        $this->__load();
        return parent::getEntitypolls();
    }

    public function setModifiedOn($modifiedOn)
    {
        $this->__load();
        return parent::setModifiedOn($modifiedOn);
    }

    public function getModifiedOn()
    {
        $this->__load();
        return parent::getModifiedOn();
    }

    public function setSerialized($serialized)
    {
        $this->__load();
        return parent::setSerialized($serialized);
    }

    public function getSerialized()
    {
        $this->__load();
        return parent::getSerialized();
    }


    public function __sleep()
    {
        return array('__isInitialized__', 'id', 'title', 'version', 'description', 'type', 'level', 'alignment', 'divide', 'number_question', 'duration', 'period', 'sequence_question', 'status', 'current_version', 'original_id', 'modified_on', 'serialized', 'created', 'changed', 'created_by', 'modified_by', 'pollsections', 'pollquestions', 'pollschedulings', 'entitypolls', 'category');
    }

    public function __clone()
    {
        if (!$this->__isInitialized__ && $this->_entityPersister) {
            $this->__isInitialized__ = true;
            $class = $this->_entityPersister->getClassMetadata();
            $original = $this->_entityPersister->load($this->_identifier);
            if ($original === null) {
                throw new \Doctrine\ORM\EntityNotFoundException();
            }
            foreach ($class->reflFields as $field => $reflProperty) {
                $reflProperty->setValue($this, $reflProperty->getValue($original));
            }
            unset($this->_entityPersister, $this->_identifier);
        }
        
    }
}