Get the proxied entity. Since there could many entities proxied. The getObject method will try to
load all the proxied entities of the same type in order to reduce the number of calls
to the storage later on.

@return AnDomainEntityAbstract
422054
public function getObject()
    {
        //security check
        if (!isset($this->_object)) {
            $condition = array($this->_property => $this->_value);
            $repository = AnDomain::getRepository($this->getIdentifier());

            //check if an entity exiting in the repository with $condition
            if ($data = $repository->find($condition, false)) {
                $this->_object = $data;

                return $this->_object;
            }

            //now time to fetch the object from the database
            //but lets grab all the similar entities all together
            $handle = $this->getIdentifier().$this->_property;
            $values = isset(self::$_values[$handle]) ? self::$_values[$handle] : array();

            if (empty($values)) {
                return;
            }

            $values = AnHelperArray::unique($values);
            $query = $repository->getQuery();
            AnDomainQueryHelper::applyFilters($query, $this->_relationship->getQueryFilters());
            $query->where(array($this->_property => $values));
            $entities = $repository->fetchSet($query);

            //the object must have been fetched with the set
            //in the previous line
            //if the object is still not fetched, then the object
            //doesn't exists in the databse
            $this->_object = $repository->find($condition, false);

            if (!$this->_object) {
                //lets cache the null result to prevent re-fetching
                //the same result
                $query = $repository->getQuery()->where($condition)->limit(1);

                if ($repository->hasBehavior('cachable')) {
                    $repository->emptyCache($query);
                }

                $this->_object = false;

                //if it's a required one-to-one relationship
                //then instantaite a new entity if the entity doesn't exists
                if ($this->_relationship->isOneToOne()) {
                    if ($this->_relationship->isRequired()) {
                        $this->_object = $repository->getEntity(array(
                            'data' => array($this->_property => $this->_value),
                        ));
                    }
                }
            }

            unset(self::$_values[$handle]);
        }

        return $this->_object;
    }
394984
protected function proxy() {
        if (!$this->context) {
            $this->context = new ApplicationContext(
                $this->version,
                $this->solution['accountSid'],
                $this->solution['sid']
            );
        }

        return $this->context;
    }
489002
public static function get()
    {
        if (SettingsServer::isTrackerApiRequest()) {
            return Tracker::getDatabase();
        }

        if (!self::hasDatabaseObject()) {
            self::createDatabaseObject();
        }

        return self::$connection;
    }
415118
public function loadObject()
    {
        $serializedObject = $this->loadSerializedObject();
        $object = unserialize($serializedObject);
        
        if ($object === false) {
            return false;
        }
        
        return $object;
    }
1364668
protected function proxy() {
        if (!$this->context) {
            $this->context = new BuildContext(
                $this->version,
                $this->solution['serviceSid'],
                $this->solution['sid']
            );
        }

        return $this->context;
    }
949240
public <T> Key<T> getKey(final T entity) {
        T unwrapped = entity;
        if (unwrapped instanceof ProxiedEntityReference) {
            final ProxiedEntityReference proxy = (ProxiedEntityReference) unwrapped;
            return (Key<T>) proxy.__getKey();
        }

        unwrapped = ProxyHelper.unwrap(unwrapped);
        if (unwrapped instanceof Key) {
            return (Key<T>) unwrapped;
        }

        final Object id = getId(unwrapped);
        final Class<T> aClass = (Class<T>) unwrapped.getClass();
        return id == null ? null : new Key<T>(aClass, getCollectionName(aClass), id);
    }
425571
public function getObject()
    {
        if ($this->thawedObject === null) {
            $this->thawedObject = $this->storage->fetch($this->id);
        }

        return $this->thawedObject;
    }
927438
public static function get($object): Proxy
    {
        if (self::$proxies === null) {
            self::$proxies = new \SplObjectStorage();
        }

        if (!isset(self::$proxies[$object])) {
            self::$proxies[$object] = new Proxy($object);
        }

        return self::$proxies[$object];
    }
1314611
protected function proxy() {
        if (!$this->context) {
            $this->context = new RoomRecordingContext(
                $this->version,
                $this->solution['roomSid'],
                $this->solution['sid']
            );
        }

        return $this->context;
    }
699034
protected function getContentInfo()
    {
        if ($this->object === null) {
            if ($this->contentInfoProxy === null) {
                $this->contentInfoProxy = new ContentContentInfoProxy($this, $this->id);
            }

            return $this->contentInfoProxy;
        } elseif ($this->contentInfoProxy !== null) {
            // Remove ref when we no longer need the proxy
            $this->contentInfoProxy = null;
        }

        return $this->object->getVersionInfo()->getContentInfo();
    }
1285358
public function getAuthObject()
    {
        if (!$this->_resultRow) {
            return false;
        }

        if (null === $this->_tableName || null === $this->_identityColumn || null === $this->_identity) {
            return false;
        }

        $dbSelect = \Doctrine_Query::create()
                ->from("$this->_tableName table")
                ->where("table.$this->_identityColumn = ?", $this->_identity);

        foreach ($this->_conditions as $condition => $value) {
            $dbSelect->addWhere($condition, $value);
        }

        $returnObject = $dbSelect->fetchOne();

        if ($returnObject) {
            return $returnObject;
        } else {
            return false;
        }
    }
1280909
public function getProxy()
    {
        if (!$this->proxy instanceof YumlProxy) {
            $this->setProxy($this->getServiceLocator()->get('dlcdiagramm_yuml_proxy'));
        }
        return $this->proxy;
    }
71350
protected function proxy() {
        if (!$this->context) {
            $this->context = new OriginationUrlContext(
                $this->version,
                $this->solution['trunkSid'],
                $this->solution['sid']
            );
        }

        return $this->context;
    }
35997
protected function proxy() {
        if (!$this->context) {
            $this->context = new FunctionContext(
                $this->version,
                $this->solution['serviceSid'],
                $this->solution['sid']
            );
        }

        return $this->context;
    }
1240172
public function get()
    {
        if (! $this->singleton) {
            return call_user_func($this->loader);
        }
        if ($this->object === null) {
            $this->object = call_user_func($this->loader);
        }

        return $this->object;
    }
914402
final public function fetch()
    {
        if(!isset($this->_entity))
        {
            $context = $this->getContext();

            if ($this->invokeCommand('before.fetch', $context) !== false)
            {
                $context->result = $this->_actionFetch($context);
                $this->invokeCommand('after.fetch', $context);
            }

            $this->_entity = ObjectConfig::unbox($context->result);
        }

        return $this->_entity;
    }
382219
protected function getObject()
    {
        $object = $this->storage->getObject();
        if (!($object instanceof StoredEntity))
        {
            $object = new StoredEntity();
        }
        return $object;
    }