PHP Class Doctrine\ODM\CouchDB\DocumentManager

Inheritance: implements Doctrine\Common\Persistence\ObjectManager
Afficher le fichier Open project: doctrine/couchdb-odm Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( Doctrine\CouchDB\CouchDBClient $couchClient, Configuration $config = null, Doctrine\Common\EventManager $evm = null )
clear ( string $objectName = null ) Clears the ObjectManager. All objects that are currently managed by this ObjectManager become detached.
contains ( object $document ) : boolean
create ( array | Doctrine\CouchDB\CouchDBClient $couchParams, Configuration $config = null, Doctrine\Common\EventManager $evm = null ) : DocumentManager Factory method for a Document Manager.
createLuceneQuery ( string $designDocName, string $viewName ) : ODMLuceneQuery Create a CouchDB-Lucene Query.
createNativeQuery ( string $designDocName, string $viewName ) : Doctrine\CouchDB\View\Query Create a Native query for the view of the specified design document.
createQuery ( string $designDocName, string $viewName ) : ODMQuery Create a Query for the view in the specified design document.
detach ( $document )
find ( string $documentName, string $id ) : object Find the Document with the given id.
flush ( )
getClassMetadata ( string $class ) : ClassMetadata
getClassMetadataFactory ( ) : ClassMetadataFactory
getConfiguration ( ) : Configuration
getCouchDBClient ( ) : Doctrine\CouchDB\CouchDBClient
getDatabase ( )
getEventManager ( ) : Doctrine\Common\EventManager
getHttpClient ( )
getMetadataFactory ( ) : ClassMetadataFactory
getProxyFactory ( ) : ProxyFactory
getReference ( string $documentName, mixed $identifier ) : object Gets a reference to the entity identified by the given type and identifier without actually loading it, if the entity is not yet loaded.
getRepository ( string $documentName ) : DocumentRepository
getUnitOfWork ( ) : UnitOfWork
initializeObject ( object $obj ) Initialize an object that is a lazy load proxy, or do nothing.
merge ( $document )
persist ( $object )
refresh ( object $document ) Refresh the given document by querying the CouchDB to get the current state.
remove ( $object )

Method Details

__construct() public méthode

public __construct ( Doctrine\CouchDB\CouchDBClient $couchClient, Configuration $config = null, Doctrine\Common\EventManager $evm = null )
$couchClient Doctrine\CouchDB\CouchDBClient
$config Configuration
$evm Doctrine\Common\EventManager

clear() public méthode

Clears the ObjectManager. All objects that are currently managed by this ObjectManager become detached.
public clear ( string $objectName = null )
$objectName string if given, only objects of this type will get detached

contains() public méthode

public contains ( object $document ) : boolean
$document object
Résultat boolean

create() public static méthode

Factory method for a Document Manager.
public static create ( array | Doctrine\CouchDB\CouchDBClient $couchParams, Configuration $config = null, Doctrine\Common\EventManager $evm = null ) : DocumentManager
$couchParams array | Doctrine\CouchDB\CouchDBClient
$config Configuration
$evm Doctrine\Common\EventManager
Résultat DocumentManager

createLuceneQuery() public méthode

Create a CouchDB-Lucene Query.
public createLuceneQuery ( string $designDocName, string $viewName ) : ODMLuceneQuery
$designDocName string
$viewName string
Résultat Doctrine\ODM\CouchDB\View\ODMLuceneQuery

createNativeQuery() public méthode

A native query will return an array of data from the &include_docs=true parameter.
public createNativeQuery ( string $designDocName, string $viewName ) : Doctrine\CouchDB\View\Query
$designDocName string
$viewName string
Résultat Doctrine\CouchDB\View\Query

createQuery() public méthode

Create a Query for the view in the specified design document.
public createQuery ( string $designDocName, string $viewName ) : ODMQuery
$designDocName string
$viewName string
Résultat Doctrine\ODM\CouchDB\View\ODMQuery

detach() public méthode

public detach ( $document )

find() public méthode

Will return null if the document wasn't found.
public find ( string $documentName, string $id ) : object
$documentName string
$id string
Résultat object

flush() public méthode

public flush ( )

getClassMetadata() public méthode

public getClassMetadata ( string $class ) : ClassMetadata
$class string
Résultat Doctrine\ODM\CouchDB\Mapping\ClassMetadata

getClassMetadataFactory() public méthode

public getClassMetadataFactory ( ) : ClassMetadataFactory
Résultat Doctrine\ODM\CouchDB\Mapping\ClassMetadataFactory

getConfiguration() public méthode

public getConfiguration ( ) : Configuration
Résultat Configuration

getCouchDBClient() public méthode

public getCouchDBClient ( ) : Doctrine\CouchDB\CouchDBClient
Résultat Doctrine\CouchDB\CouchDBClient

getDatabase() public méthode

public getDatabase ( )

getEventManager() public méthode

public getEventManager ( ) : Doctrine\Common\EventManager
Résultat Doctrine\Common\EventManager

getHttpClient() public méthode

public getHttpClient ( )

getMetadataFactory() public méthode

public getMetadataFactory ( ) : ClassMetadataFactory
Résultat Doctrine\ODM\CouchDB\Mapping\ClassMetadataFactory

getProxyFactory() public méthode

public getProxyFactory ( ) : ProxyFactory
Résultat Doctrine\ODM\CouchDB\Proxy\ProxyFactory

getReference() public méthode

Gets a reference to the entity identified by the given type and identifier without actually loading it, if the entity is not yet loaded.
public getReference ( string $documentName, mixed $identifier ) : object
$documentName string The name of the entity type.
$identifier mixed The entity identifier.
Résultat object The entity reference.

getRepository() public méthode

public getRepository ( string $documentName ) : DocumentRepository
$documentName string
Résultat DocumentRepository

getUnitOfWork() public méthode

public getUnitOfWork ( ) : UnitOfWork
Résultat UnitOfWork

initializeObject() public méthode

Initialize an object that is a lazy load proxy, or do nothing.
public initializeObject ( object $obj )
$obj object

merge() public méthode

public merge ( $document )

persist() public méthode

public persist ( $object )

refresh() public méthode

Refresh the given document by querying the CouchDB to get the current state.
public refresh ( object $document )
$document object

remove() public méthode

public remove ( $object )