mirror of
https://github.com/danog/sql.git
synced 2024-11-26 20:15:08 +01:00
Add cancellation to connect()
This commit is contained in:
parent
dcbe6ff712
commit
52a30eeded
@ -2,11 +2,13 @@
|
||||
|
||||
namespace Amp\Sql;
|
||||
|
||||
use Amp\Cancellation;
|
||||
|
||||
interface SqlConnector
|
||||
{
|
||||
/**
|
||||
* Returns a new database connection based on the given configuration.
|
||||
* Implementations may provide further parameters, such as a Cancellation.
|
||||
*/
|
||||
public function connect(SqlConfig $config): Link;
|
||||
public function connect(SqlConfig $config, ?Cancellation $cancellation = null): Link;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user