class InvokedProcessPool implements Countable, IteratorAggregate

Methods

__construct(array $invokedProcesses)

Create a new invoked process pool.

signal(int $signal)

Send a signal to each running process in the pool, returning the processes that were signalled.

stop(float $timeout = 10, int|null $signal = null)

Stop all processes that are still running.

running()

Get the processes in the pool that are still currently running.

wait()

Wait for the processes to finish.

int
count()

Get the total number of processes.

getIterator()

Get an iterator for the invoked processes.

Details

at line 25
__construct(array $invokedProcesses)

Create a new invoked process pool.

Parameters

array $invokedProcesses

the array of invoked processes

at line 32
Collection signal(int $signal)

Send a signal to each running process in the pool, returning the processes that were signalled.

Parameters

int $signal

Return Value

Collection

at line 40
Collection stop(float $timeout = 10, int|null $signal = null)

Stop all processes that are still running.

Parameters

float $timeout
int|null $signal

Return Value

Collection

at line 80
Collection running()

Get the processes in the pool that are still currently running.

Return Value

Collection

at line 91
ProcessPoolResults wait()

Wait for the processes to finish.

Return Value

ProcessPoolResults

at line 116
int count()

Get the total number of processes.

Return Value

int

at line 126
Traversable getIterator()

Get an iterator for the invoked processes.

Return Value

Traversable