This commit is contained in:
li
2026-01-28 23:48:20 +08:00
commit b8cd0c9418
1293 changed files with 184011 additions and 0 deletions
@@ -0,0 +1,33 @@
<?php
namespace Smf\ConnectionPool;
interface ConnectionPoolInterface
{
/**
* Initialize the connection pool
* @return bool
*/
public function init(): bool;
/**
* Return a connection to the connection pool
* @param mixed $connection
* @return bool
*/
public function return($connection): bool;
/**
* Borrow a connection to the connection pool
* @return mixed
* @throws BorrowConnectionTimeoutException
*/
public function borrow();
/**
* Close the connection pool, release the resource of all connections
* @return bool
*/
public function close(): bool;
}