TaskPool


TaskPool

  • Full name: \venndev\vosaka\runtime\eventloop\task\TaskPool

  • This class is marked as final and can't be subclassed

  • This class is a Final class

Properties

pool

private \SplQueue $pool

maxPoolSize

private int $maxPoolSize

created

private int $created

reused

private int $reused

Methods

__construct

public __construct(int $maxPoolSize = 1000): mixed

Parameters:

Parameter
Type
Description

$maxPoolSize

int


getTask

public getTask(callable $callback, mixed $context = null): \venndev\vosaka\runtime\eventloop\task\Task

Parameters:

Parameter
Type
Description

$callback

callable

$context

mixed


returnTask

public returnTask(\venndev\vosaka\runtime\eventloop\task\Task $task): void

Parameters:

Parameter
Type
Description

$task

\venndev\vosaka\runtime\eventloop\task\Task


getStats

public getStats(): array


Automatically generated on 2025-06-26