public function acquire()
    {
        if (!$this->_object->isSaved()) {
            throw new LockingException("Can't lock unsaved objects");
        }

        $finder = \Pheasant::instance()->finderFor($this->_object);

        return $freshObject = $finder
            ->find($this->_object->className(), $this->_object->identity()->toCriteria())
            ->lock($this->_clause)
            ->one()
            ;
    }
public function acquire()
    {
        if (!$this->_object->isSaved()) {
            throw new LockingException("Can't lock unsaved objects");
        }

        $finder = \Pheasant::instance()->finderFor($this->_object);

        return $freshObject = $finder
            ->find($this->_object->className(), $this->_object->identity()->toCriteria())
            ->lock($this->_clause)
            ->one()
            ;
    }
public function acquire ( ) { if ( ! $ this -> _object -> isSaved ( ) ) { throw new LockingException ( "Can't lock unsaved objects" ) ; } $ finder = \ Pheasant :: instance ( ) -> finderFor ( $ this -> _object ) ; return $ freshObject = $ finder -> find ( $ this -> _object -> className ( ) , $ this -> _object -> identity ( ) -> toCriteria ( ) ) -> lock ( $ this -> _clause ) -> one ( ) ; }
Acquire the lock on the object
@return object the reloaded object
Acquire the lock on the object