Nexus API Reference

EntityManagerPool
in package

FinalYes
Tags
psalm-api
psalm-type

EmMeta = array{conn: Connection}

Table of Contents

Methods

__construct()  : mixed
close()  : void
name()  : string
release()  : void
stats()  : EmPoolStats
take()  : PooledEntityManager
withEntityManager()  : T

Methods

__construct()

public __construct(string $name, EntityManagerFactory $factory, ConnectionPool $connPool, EmPoolConfig $config, Channel<string|int, PooledEntityManager$channel[, EventDispatcherInterface|null $events = null ][, LoggerInterface $logger = new NullLogger() ]) : mixed
Parameters
$name : string
$factory : EntityManagerFactory
$connPool : ConnectionPool
$config : EmPoolConfig
$channel : Channel<string|int, PooledEntityManager>
$events : EventDispatcherInterface|null = null
$logger : LoggerInterface = new NullLogger()

close()

public close(Duration $timeout) : void
Parameters
$timeout : Duration
Tags
psalm-suppress

UnusedParam Parameter kept for API symmetry with ConnectionPool::close(); current drain is sync, no deadline needed yet.

withEntityManager()

public withEntityManager(callable(EntityManagerInterface): T $fn) : T
Parameters
$fn : callable(EntityManagerInterface): T
Tags
template

T

Return values
T

        
On this page

Search results