Maslosoft Mangan API
Interface EntityManagerInterface
Direct known implementers
Maslosoft\Mangan\EntityManager
,
Maslosoft\Mangan\Interfaces\ActiveRecordInterface
Indirect known implementers
Maslosoft\Mangan\Document
,
Maslosoft\Mangan\Example\ExampleUser
,
Maslosoft\Mangan\Model\Trash
,
Maslosoft\Mangan\Model\TrashItem
Author: Piotr Maselkowski
Located at Interfaces/EntityManagerInterface.php
Methods summary
public
boolean
|
|
public
boolean
|
#
insert( Maslosoft\Addendum\Interfaces\AnnotatedInterface $model = null )
Inserts a row into the table based on this active record attributes. If the table's primary key is auto-incremental and is null before insertion, it will be populated with the actual value after insertion. Note, validation is not performed in this method. You may call validate to perform the validation. After the record is inserted to DB successfully, its isNewRecord property will be set false, and its scenario property will be set to be 'update'. |
public
boolean
|
|
public
|
#
updateOne( array|
Updates one document with the specified criteria and attributes |
public
boolean|mixed[]
|
#
updateAll(
Atomic, in-place update method. |
public
boolean
|
|
public
boolean
|
|
public
boolean
|
|
public
|
#
deleteOne( array|
Deletes one document with the specified primary key or by passed criteria. |
public
|
#
deleteByPk( mixed $pkValue, array|
Deletes document with the specified primary key with optional criteria. |
public
|
#
deleteAllByPk( mixed[] $pkValues, array|
Deletes documents with the specified primary keys. |
public
|
#
deleteAll( array|
Deletes all documents specified by criteria. |
public
boolean
|
|
public
MongoCollection
|
Constants summary
string |
EventBeforeSave
|
#
'beforeSave'
|
string |
EventAfterSave
|
#
'afterSave'
|
string |
EventBeforeInsert
|
#
'beforeInsert'
|
string |
EventAfterInsert
|
#
'afterInsert'
|
string |
EventBeforeUpdate
|
#
'beforeUpdate'
|
string |
EventAfterUpdate
|
#
'afterUpdate'
|
string |
EventBeforeDelete
|
#
'beforeDelete'
|
string |
EventAfterDelete
|
#
'afterDelete'
|