Свойство | Тип | Описание | |
---|---|---|---|
$connection | |||
$errors | |||
$yaml_file |
Метод | Описание | |
---|---|---|
__call ( string $method, mixed $args ) : null | Trigger to use object values as methods Like $user->name("john doe"); echo $user->name(); | |
__construct ( array $data = null ) | Constructor | |
__get ( string $attr ) : attribute | Trigger to get object values as attributes Like echo $user->name; | |
__set ( string $attr, mixed $value ) : null | Trigger to set object values as attributes Like $user->name = "john doe"; | |
closeCursor ( mixed $stmt ) : null | Close cursor | |
closeCursorBehaviour ( mixed $action ) : null | Behaviour to close cursor | |
executePrepared ( mixed $obj, mixed $values = [] ) : object | Execute a prepared statement, trying to get it from cache. | |
extractColumns ( ) : string | Extract table columns string | |
extractUpdateColumns ( mixed $values ) : string | Extract update columns string | |
extractWhereConditions ( mixed $conditions ) : string | Extract where conditions string Just used for testing, to avoid change the function name withou the underline on all code. This is something PHP should change. | |
extractWhereValues ( mixed $conditions ) : mixed | Extract where values from conditions | |
get ( string $attr, boolean $current = true ) : mixed | Get an attribute value | |
getColumns ( ) : mixed | Return columns | |
getOrder ( ) : string | Returns the default order. | |
getPK ( ) : string | Returns the primary key column. | |
getReversedOrder ( ) : string | Returns the inverse order. | |
getTableName ( string $cls = null ) : string | Returns the table name. | |
hasColumn ( string $column ) : column | Check if a column exists | |
isIgnoringCase ( ) : boolean | Check if is ignoring case | |
is_new ( ) : boolean | Tell if its a new object (not saved) | |
query ( string $sql ) : mixed | Run a SQL query | |
reload ( ) : mixed | Reload the current object | |
resolveConnection ( ) : object | Resolve the current connection handle. | |
set ( string $attr, mixed $value ) : null | Set an attribute value | |
setConnection ( mixed $con, string $env = "development" ) : null | Sets a specific connection for the current model | |
setOrder ( string $order ) : null | Set the default order | |
setPK ( string $pk ) : null | Set the primary key column | |
setTableName ( string $table_name ) : null | Set the model's table name |
Метод | Описание | |
---|---|---|
_checkLoaded ( ) : boolean | Check if the object columns were loaded | |
_extractClassName ( $cls ) : string | Extract namespace from class name | |
_extractWhereAssociativeConditions ( mixed $conditions, string $cls, string $escape ) : string | Extract where conditions string, from an associative array | |
_extractWhereAssociativeValues ( mixed $conditions ) : mixed | Extract values from an associative array | |
_extractWhereConditions ( mixed $conditions ) : string | Extract where conditions string | |
_extractWhereRegularConditions ( mixed $conditions, string $cls, string $escape ) : string | Extract where conditions string, from a regular array | |
_extractWhereRegularValues ( mixed $conditions ) : mixed | Extract values from a regular array | |
_loadColumns ( ) : null | Load column info | |
_loadNullValues ( ) : null | Load null values on row columns. Useful to new objects. | |
_makeBuilder ( ) : mixed | Create a query builder | |
_resolveRelations ( string $attr ) : null | Resolve relations on an attribute, if present | |
_validateAfterInitialize ( ) : null | Validate after initialize |
public __construct ( array $data = null ) | ||
$data | array | to fill the object |
public static closeCursor ( mixed $stmt ) : null | ||
$stmt | mixed | statement |
Результат | null |
public static closeCursorBehaviour ( mixed $action ) : null | ||
$action | mixed | to use |
Результат | null |
public static extractColumns ( ) : string | ||
Результат | string | columns |
public static extractUpdateColumns ( mixed $values ) : string | ||
$values | mixed | to set columns |
Результат | string | columns |
public static extractWhereConditions ( mixed $conditions ) : string | ||
$conditions | mixed | to extract |
Результат | string | where conditions |
public static extractWhereValues ( mixed $conditions ) : mixed | ||
$conditions | mixed | to extract values |
Результат | mixed | $values |
public static getColumns ( ) : mixed | ||
Результат | mixed | columns |
public static getReversedOrder ( ) : string | ||
Результат | string | order |
public static getTableName ( string $cls = null ) : string | ||
$cls | string | class name |
Результат | string | table name |
public static isIgnoringCase ( ) : boolean | ||
Результат | boolean | ignoring case |
public static resolveConnection ( ) : object | ||
Результат | object | connection |
public static setTableName ( string $table_name ) : null | ||
$table_name | string | table name |
Результат | null |