1
0
mirror of https://github.com/dg/dibi.git synced 2025-08-04 21:28:02 +02:00

renamed DibiLazyStorage to DibiHashMap

This commit is contained in:
David Grudl
2011-01-25 18:00:29 +01:00
parent 1ada6fab97
commit 9c52b8ea9d
6 changed files with 12 additions and 12 deletions

View File

@@ -66,7 +66,7 @@ class DibiPcreException extends Exception {
require_once dirname(__FILE__) . '/libs/interfaces.php';
require_once dirname(__FILE__) . '/libs/DibiDateTime.php';
require_once dirname(__FILE__) . '/libs/DibiObject.php';
require_once dirname(__FILE__) . '/libs/DibiLazyStorage.php';
require_once dirname(__FILE__) . '/libs/DibiHashMap.php';
require_once dirname(__FILE__) . '/libs/DibiException.php';
require_once dirname(__FILE__) . '/libs/DibiConnection.php';
require_once dirname(__FILE__) . '/libs/DibiResult.php';
@@ -612,7 +612,7 @@ class dibi
/**
* Returns substitution hashmap - Monostate for DibiConnection::getSubstitutes().
* @return DibiLazyStorage
* @return DibiHashMap
*/
public static function getSubstitutes()
{

View File

@@ -42,7 +42,7 @@ class DibiConnection extends DibiObject
/** @var bool Is connected? */
private $connected = FALSE;
/** @var DibiLazyStorage Substitutes for identifiers */
/** @var DibiHashMap Substitutes for identifiers */
private $substitutes;
@@ -122,7 +122,7 @@ class DibiConnection extends DibiObject
$this->setProfiler(new $class($profilerCfg));
}
$this->substitutes = new DibiLazyStorage(create_function('$expr', 'return ":$expr:";'));
$this->substitutes = new DibiHashMap(create_function('$expr', 'return ":$expr:";'));
if (!empty($config['substitutes'])) {
foreach ($config['substitutes'] as $key => $value) {
$this->substitutes->$key = $value;
@@ -582,7 +582,7 @@ class DibiConnection extends DibiObject
/**
* Returns substitution hashmap.
* @return DibiLazyStorage
* @return DibiHashMap
*/
public function getSubstitutes()
{

View File

@@ -532,7 +532,7 @@ class DibiColumnInfo extends DibiObject
public function getType()
{
if (self::$types === NULL) {
self::$types = new DibiLazyStorage(array(__CLASS__, 'detectType'));
self::$types = new DibiHashMap(array(__CLASS__, 'detectType'));
}
return self::$types->{$this->info['nativetype']};
}

View File

@@ -94,7 +94,7 @@ class DibiFluent extends DibiObject implements IDataSource
/** @var array */
private $cursor;
/** @var DibiLazyStorage normalized clauses */
/** @var DibiHashMap normalized clauses */
private static $normalizer;
@@ -107,7 +107,7 @@ class DibiFluent extends DibiObject implements IDataSource
$this->connection = $connection;
if (self::$normalizer === NULL) {
self::$normalizer = new DibiLazyStorage(array(__CLASS__, '_formatClause'));
self::$normalizer = new DibiHashMap(array(__CLASS__, '_formatClause'));
}
}

View File

@@ -18,7 +18,7 @@
* @author David Grudl
* @internal
*/
abstract class DibiLazyStorageBase
abstract class DibiHashMapBase
{
private $callback;
@@ -50,7 +50,7 @@ abstract class DibiLazyStorageBase
final class DibiLazyStorage extends DibiLazyStorageBase
final class DibiHashMap extends DibiHashMapBase
{
public function __set($nm, $val)

View File

@@ -49,7 +49,7 @@ final class DibiTranslator extends DibiObject
/** @var int */
private $offset;
/** @var DibiLazyStorage */
/** @var DibiHashMap */
private $identifiers;
@@ -69,7 +69,7 @@ final class DibiTranslator extends DibiObject
*/
public function translate(array $args)
{
$this->identifiers = new DibiLazyStorage(array($this, 'delimite'));
$this->identifiers = new DibiHashMap(array($this, 'delimite'));
$this->driver = $this->connection->getDriver();
$args = array_values($args);