Property | Type | Description | |
---|---|---|---|
$worker_data | mixed | ||
$workers | Bravo3\Orm\Drivers\Common\WorkerInterface[] |
Method | Description | |
---|---|---|
__construct ( array $workers = [], mixed $worker_data = null ) | Creates a lazy-loading worker pool | |
addWorker ( string $name, Bravo3\Orm\Drivers\Common\WorkerInterface | string $worker ) | Adds a worker to the pool | |
execute ( |
Have the appropriate worker execute a command | |
hasWorker ( string $name ) : boolean | Check if we have a worker for a given command |
Method | Description | |
---|---|---|
getWorker ( $name ) : Bravo3\Orm\Drivers\Common\WorkerInterface | Get a worker, lazy-loading as required |
public __construct ( array $workers = [], mixed $worker_data = null ) | ||
$workers | array | Preload the pool with some workers |
$worker_data | mixed | Data to pass to worker constructors |
protected getWorker ( $name ) : Bravo3\Orm\Drivers\Common\WorkerInterface | ||
$name | ||
return | Bravo3\Orm\Drivers\Common\WorkerInterface |