function __construct(lmbUri $dsn)
 {
     parent::__construct($dsn);
     if (!$this->dsn->getHost()) {
         $this->dsn->setHost($this->default_host);
     }
     if (!$this->dsn->getPort()) {
         $this->dsn->setPort($this->default_port);
     }
     $this->_server_id = $dsn->toString(array('host', 'port'));
 }
 function __construct(lmbUri $dsn)
 {
     parent::__construct($dsn);
     $this->dsn = $dsn;
     if (!($db_dsn_name = $dsn->getHost())) {
         throw new lmbNoSuchPropertyException('DB DSN name not found in cache DSN', array('cache dsn' => $dsn));
     }
     if (!($db_table_name = $dsn->getQueryItem('table'))) {
         throw new lmbNoSuchPropertyException('DB table name not found in cache DSN', array('cache dsn' => $dsn));
     }
     $db_connection = lmbToolkit::instance()->getDbConnectionByName($db_dsn_name);
     $this->db_table = new lmbTableGateway($db_table_name, $db_connection);
 }
 /**
  * @param lmbUri $dsn
  */
 function __construct($dsn)
 {
     parent::__construct($dsn);
     $this->_cache_dir = $this->dsn->getPath();
     lmbFs::mkdir($this->_cache_dir);
 }
 function testUnlock()
 {
     $this->assertTrue($this->cache->lock($id = $this->_getUniqueId('testUnlock')));
     $this->cache->unlock($id);
     $this->assertTrue($this->cache->lock($id));
 }