<?php

namespace Proxies\__CG__\Entities;

/**
 * THIS CLASS WAS GENERATED BY THE DOCTRINE ORM. DO NOT EDIT THIS FILE.
 */
class Profile extends \Entities\Profile 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 setName($name)
    {
        $this->__load();
        return parent::setName($name);
    }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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


    public function __sleep()
    {
        return array('__isInitialized__', 'id', 'name', 'description', 'about', 'address1', 'address2', 'maps', 'site_web', 'tel', 'mobile', 'fax', 'email_contact', 'email_notification', 'post');
    }

    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);
        }
        
    }
}