SQLSessionInit
in package
implements
EventSubscriber
Session init listener for executing a single SQL statement right after a connection is opened.
Tags
Interfaces, Classes and Traits
- EventSubscriber
- An EventSubscriber knows himself what events he is interested in.
Table of Contents
- $sql : string
- __construct() : mixed
- getSubscribedEvents() : array<string|int, mixed>
- Returns an array of events this subscriber wants to listen to.
- postConnect() : void
Properties
$sql
protected
string
$sql
Methods
__construct()
public
__construct(string $sql) : mixed
Parameters
- $sql : string
Return values
mixed —getSubscribedEvents()
Returns an array of events this subscriber wants to listen to.
public
getSubscribedEvents() : array<string|int, mixed>
Return values
array<string|int, mixed> —postConnect()
public
postConnect(ConnectionEventArgs $args) : void
Parameters
- $args : ConnectionEventArgs