23   private $_objectId = null;
 
   25   private $_created = 
"";
 
   26   private $_currentState = null;
 
   35   public function __construct($type, $oid, $login, $created=
'') {
 
   37     $this->_objectId = $oid;
 
   38     $this->_login = $login;
 
   40       $this->_created = date(
"Y-m-d H:i:s");
 
   43       $this->_created = $created;
 
   60     return $this->_objectId;
 
   76     return $this->_created;
 
   85     $this->_currentState = serialize($currentState);
 
   94     return unserialize($this->_currentState);
 
getObjectId()
Get the oid of the locked object. 
 
setCurrentState($currentState)
Set the original state of the object in case of an optimistic lock. 
 
Lock represents a lock on an object. 
 
__construct($type, $oid, $login, $created='')
Creates a lock on a given object. 
 
getCurrentState()
Get the original state of the object in case of an optimistic lock. 
 
getCreated()
Get the creation date/time of the lock. 
 
getLogin()
Get the login of the user who holds the lock. 
 
getType()
Get the type of the lock.