Property | Type | Description | |
---|---|---|---|
$cache_individual_model | Whether to cache individual models or not (not to be confused with caching of table schemas). | ||
$cache_model_expire | Expiration period for model caching. | ||
$callback | A instance of CallBack for this model/table | ||
$class | |||
$columns | Name/value pairs of columns in this table | ||
$conn | |||
$db_name | Name of the database (optional) | ||
$last_sql | |||
$pk | |||
$sequence | Name of the sequence for this table (optional). Defaults to {$table}_seq | ||
$table | Name of the table. |
Method | Description | |
---|---|---|
__construct ( $class_name ) | ||
cache_key_for_model ( $pk ) | ||
clear_cache ( $model_class_name = null ) | ||
create_joins ( $joins ) | ||
delete ( $data ) | ||
find ( $options ) | ||
find_by_sql ( $sql, $values = null, $readonly = false, $includes = null ) | ||
get_column_by_inflected_name ( $inflected_name ) | ||
get_fully_qualified_table_name ( $quote_name = true ) | ||
get_relationship ( $name, $strict = false ) : activerecord\HasOne | |
Retrieve a relationship object for this table. Strict as true will throw an error if the relationship name does not exist. | |
has_relationship ( $name ) : boolean | Does a given relationship exist? | |
insert ( &$data, $pk = null, $sequence_name = null ) | ||
load ( $model_class_name ) | ||
options_to_sql ( $options ) | ||
reestablish_connection ( $close = true ) | ||
update ( &$data, $where ) |
Method | Description | |
---|---|---|
add_relationship ( Relationship $relationship ) | Add a relationship. | |
execute_eager_load ( $models = [], $attrs = [], $includes = [] ) : void | Executes an eager load of a given named relationship for this table. | |
get_meta_data ( ) | ||
map_names ( &$hash, &$map ) : array | Replaces any aliases used in a hash based condition. | |
process_data ( $hash ) | ||
set_associations ( ) | ||
set_cache ( ) | ||
set_delegates ( ) | Rebuild the delegates array into format that we can more easily work with in Model. | |
set_primary_key ( ) | ||
set_sequence_name ( ) | ||
set_setters_and_getters ( ) | ||
set_table_name ( ) |
public find_by_sql ( $sql, $values = null, $readonly = false, $includes = null ) |
public get_column_by_inflected_name ( $inflected_name ) |
public get_fully_qualified_table_name ( $quote_name = true ) |
public get_relationship ( $name, $strict = false ) : activerecord\HasOne | |
||
$name | string name of Relationship | |
$strict | bool | |
return | activerecord\HasOne | |
Relationship or null |
public has_relationship ( $name ) : boolean | ||
$name | string name of Relationship | |
return | boolean |
public $cache_individual_model |
public $sequence |