Property | Type | Description | |
---|---|---|---|
$arrAliases | array | Aliases to PK's by table and column | |
$arrIdentities | array | Models by object hash | |
$arrRegistry | array | Models by table and PK | |
$objInstance | static | Object instance (Singleton) |
Method | Description | |
---|---|---|
__clone ( ) | Prevent cloning of the object (Singleton) | |
count ( ) : integer | Count the elements | |
fetch ( string $strTable, mixed $varKey, string $strAlias = null ) : |
Fetch a model by table name and primary key | |
fetchByAlias ( string $strTable, string $strAlias, mixed $varValue ) : |
Fetch a model by one of its aliases | |
getInstance ( ) : static | Return the current object instance (Singleton) | |
isRegistered ( |
Check if a model is registered | |
isRegisteredAlias ( |
Check if an alias is registered | |
register ( |
Register a model in the registry | |
registerAlias ( |
Register an alias for a model | |
unregister ( |
Unregister a model from the registry | |
unregisterAlias ( |
Unregister an alias |
Method | Description | |
---|---|---|
__construct ( ) | Prevent direct instantiation (Singleton) |
public static getInstance ( ) : static | ||
return | static | The object instance |
public isRegistered ( |
||
$objModel | The model object | |
return | boolean | True if the model is registered |
public register ( |
||
$objModel | The model object |
public registerAlias ( |
||
$objModel | The model object | |
$strAlias | string | The alias name |
$varValue | mixed | The value of the alias |
public unregister ( |
||
$objModel | The model object |
public unregisterAlias ( |
||
$objModel | The model object | |
$strAlias | string | The alias name |
$varValue | mixed | The value of the alias |
protected array $arrAliases | ||
return | array |
protected array $arrIdentities | ||
return | array |