multi-store/vendor/hyperf/contract/src/PoolInterface.php
2024-05-31 09:27:37 +08:00

34 lines
702 B
PHP

<?php
declare(strict_types=1);
/**
* This file is part of Hyperf.
*
* @link https://www.hyperf.io
* @document https://hyperf.wiki
* @contact group@hyperf.io
* @license https://github.com/hyperf/hyperf/blob/master/LICENSE
*/
namespace Hyperf\Contract;
interface PoolInterface
{
/**
* Get a connection from the connection pool.
*/
public function get(): ConnectionInterface;
/**
* Release a connection back to the connection pool.
*/
public function release(ConnectionInterface $connection): void;
/**
* Close and clear the connection pool.
*/
public function flush(): void;
public function getOption(): PoolOptionInterface;
}