Bundle/WidgetBundle/Entity/Widget.php
public function getEntity()
    {
        //if there is no entity
        if ($this->entity === null) {
            //we try to get one from the proxy
            $entityProxy = $this->getEntityProxy();

            //if there is a proxy
            if ($entityProxy !== null && $this->getBusinessEntityId()) {
                $entity = $entityProxy->getEntity($this->getBusinessEntityId());
                $this->entity = $entity;
            }
        }

        return $this->entity;
    }
public function getEntity()
    {
        //if there is no entity
        if ($this->entity === null) {
            //we try to get one from the proxy
            $entityProxy = $this->getEntityProxy();

            //if there is a proxy
            if ($entityProxy !== null && $this->getBusinessEntityId()) {
                $entity = $entityProxy->getEntity($this->getBusinessEntityId());
                $this->entity = $entity;
            }
        }

        return $this->entity;
    }
public function getEntity ( ) { //if there is no entity if ( $ this -> entity === null ) { //we try to get one from the proxy $ entityProxy = $ this -> getEntityProxy ( ) ; //if there is a proxy if ( $ entityProxy !== null && $ this -> getBusinessEntityId ( ) ) { $ entity = $ entityProxy -> getEntity ( $ this -> getBusinessEntityId ( ) ) ; $ this -> entity = $ entity ; } } return $ this -> entity ; }
Get the entity.

@return number
Get the entity .