Inheritance diagram for Junction:Represents a junction table, derived from an annotated interface.
Interface Annotations:
@junction <TABLE>@foreign <COLUMN> <CLASS FQN> Protected Properties | |
| string[] | $classes = [] |
[column => class] More... | |
| Reflection | $ref |
Protected Properties inherited from Table | |
| Statement[] | $_cache = [] |
| Prepared statement cache, keyed by function name. More... | |
| Column[] | $columns = [] |
[name => Column] More... | |
| string | $name |
Protected Properties inherited from AbstractTable | |
| DB | $db |
Public Static Methods | |
| magic static self | factory (DB $db, string $interface) |
Public Static Methods inherited from Table | |
| magic static self | factory (DB $db, string $name, array $columns) |
Public Methods | |
| __construct (DB $db, string $interface) | |
| Select EntityInterface[] | findAll (string $key, array $match=[]) |
| Returns a Select for entities referenced by a foreign key. More... | |
| string | getClass (string $column) |
| string[] | getClasses () |
| Record | getRecord (string $column) |
| Record[] | getRecords () |
| int | link (array $ids) |
INSERT IGNORE to link entities. More... | |
| int | unlink (array $ids) |
| Typed alias for delete(). More... | |
Public Methods inherited from Table | |
| __construct (DB $db, string $name, array $columns) | |
| string | __toString () |
| Returns the table name. More... | |
| int | apply (array $values) |
INSERT IGNORE More... | |
| int | count (array $match=[]) |
| int | delete (array $match) |
| Executes a deletion using arbitrary columns. More... | |
| Column[] | getColumns () |
| string | getName () |
| Statement | insert (array $values) |
| Executes an insertion using arbitrary columns. More... | |
| Column | offsetGet ($column) |
| Select array[] | select ($expressions=[' *']) |
| Returns a selection object for columns or expressions in the table. More... | |
| Table | setName (string $name) |
| Returns an aliased clone for joins. More... | |
| int | update (array $values, array $match) |
| Executes an update using arbitrary columns. More... | |
Public Methods inherited from AbstractTable | |
| __construct (DB $db) | |
| bool | offsetExists ($column) |
| void | offsetSet ($offset, $value) |
| Throws. More... | |
| void | offsetUnset ($name) |
| Throws. More... | |
Additional Inherited Members | |
Protected Methods inherited from Table | |
| Statement | cache (string $key, Closure $prepare) |
| Caches a prepared statement. More... | |
|
protected |
[column => class]
| Select EntityInterface [] findAll | ( | string | $key, |
| array | $match = [] |
||
| ) |
|
final |
| string | $column |
|
final |
| int link | ( | array | $ids | ) |
INSERT IGNORE to link entities.
| int[] | EntityInterface[] | $ids | Keyed by column |
| int unlink | ( | array | $ids | ) |
Typed alias for delete().
| int[] | EntityInterface[] | $ids | Keyed by column |