| @@ 31-70 (lines=40) @@ | ||
| 28 | * |
|
| 29 | * @author Adam Kadlec <[email protected]> |
|
| 30 | */ |
|
| 31 | final class CloseEvent extends EventDispatcher\Event |
|
| 32 | { |
|
| 33 | /** |
|
| 34 | * @var Mqtt\Connection |
|
| 35 | */ |
|
| 36 | private $connection; |
|
| 37 | ||
| 38 | /** |
|
| 39 | * @var Client\IClient |
|
| 40 | */ |
|
| 41 | private $client; |
|
| 42 | ||
| 43 | /** |
|
| 44 | * @param Mqtt\Connection $connection |
|
| 45 | * @param Client\IClient $client |
|
| 46 | */ |
|
| 47 | public function __construct( |
|
| 48 | Mqtt\Connection $connection, |
|
| 49 | Client\IClient $client |
|
| 50 | ) { |
|
| 51 | $this->connection = $connection; |
|
| 52 | $this->client = $client; |
|
| 53 | } |
|
| 54 | ||
| 55 | /** |
|
| 56 | * @return Mqtt\Connection |
|
| 57 | */ |
|
| 58 | public function getConnection() : Mqtt\Connection |
|
| 59 | { |
|
| 60 | return $this->connection; |
|
| 61 | } |
|
| 62 | ||
| 63 | /** |
|
| 64 | * @return Client\IClient |
|
| 65 | */ |
|
| 66 | public function getClient() : Client\IClient |
|
| 67 | { |
|
| 68 | return $this->client; |
|
| 69 | } |
|
| 70 | } |
|
| 71 | ||
| @@ 31-70 (lines=40) @@ | ||
| 28 | * |
|
| 29 | * @author Adam Kadlec <[email protected]> |
|
| 30 | */ |
|
| 31 | final class ConnectEvent extends EventDispatcher\Event |
|
| 32 | { |
|
| 33 | /** |
|
| 34 | * @var Mqtt\Connection |
|
| 35 | */ |
|
| 36 | private $connection; |
|
| 37 | ||
| 38 | /** |
|
| 39 | * @var Client\IClient |
|
| 40 | */ |
|
| 41 | private $client; |
|
| 42 | ||
| 43 | /** |
|
| 44 | * @param Mqtt\Connection $connection |
|
| 45 | * @param Client\IClient $client |
|
| 46 | */ |
|
| 47 | public function __construct( |
|
| 48 | Mqtt\Connection $connection, |
|
| 49 | Client\IClient $client |
|
| 50 | ) { |
|
| 51 | $this->connection = $connection; |
|
| 52 | $this->client = $client; |
|
| 53 | } |
|
| 54 | ||
| 55 | /** |
|
| 56 | * @return Mqtt\Connection |
|
| 57 | */ |
|
| 58 | public function getConnection() : Mqtt\Connection |
|
| 59 | { |
|
| 60 | return $this->connection; |
|
| 61 | } |
|
| 62 | ||
| 63 | /** |
|
| 64 | * @return Client\IClient |
|
| 65 | */ |
|
| 66 | public function getClient() : Client\IClient |
|
| 67 | { |
|
| 68 | return $this->client; |
|
| 69 | } |
|
| 70 | } |
|
| 71 | ||
| @@ 31-70 (lines=40) @@ | ||
| 28 | * |
|
| 29 | * @author Adam Kadlec <[email protected]> |
|
| 30 | */ |
|
| 31 | final class DisconnectEvent extends EventDispatcher\Event |
|
| 32 | { |
|
| 33 | /** |
|
| 34 | * @var Mqtt\Connection |
|
| 35 | */ |
|
| 36 | private $connection; |
|
| 37 | ||
| 38 | /** |
|
| 39 | * @var Client\IClient |
|
| 40 | */ |
|
| 41 | private $client; |
|
| 42 | ||
| 43 | /** |
|
| 44 | * @param Mqtt\Connection $connection |
|
| 45 | * @param Client\IClient $client |
|
| 46 | */ |
|
| 47 | public function __construct( |
|
| 48 | Mqtt\Connection $connection, |
|
| 49 | Client\IClient $client |
|
| 50 | ) { |
|
| 51 | $this->connection = $connection; |
|
| 52 | $this->client = $client; |
|
| 53 | } |
|
| 54 | ||
| 55 | /** |
|
| 56 | * @return Mqtt\Connection |
|
| 57 | */ |
|
| 58 | public function getConnection() : Mqtt\Connection |
|
| 59 | { |
|
| 60 | return $this->connection; |
|
| 61 | } |
|
| 62 | ||
| 63 | /** |
|
| 64 | * @return Client\IClient |
|
| 65 | */ |
|
| 66 | public function getClient() : Client\IClient |
|
| 67 | { |
|
| 68 | return $this->client; |
|
| 69 | } |
|
| 70 | } |
|
| 71 | ||
| @@ 31-70 (lines=40) @@ | ||
| 28 | * |
|
| 29 | * @author Adam Kadlec <[email protected]> |
|
| 30 | */ |
|
| 31 | final class OpenEvent extends EventDispatcher\Event |
|
| 32 | { |
|
| 33 | /** |
|
| 34 | * @var Mqtt\Connection |
|
| 35 | */ |
|
| 36 | private $connection; |
|
| 37 | ||
| 38 | /** |
|
| 39 | * @var Client\IClient |
|
| 40 | */ |
|
| 41 | private $client; |
|
| 42 | ||
| 43 | /** |
|
| 44 | * @param Mqtt\Connection $connection |
|
| 45 | * @param Client\IClient $client |
|
| 46 | */ |
|
| 47 | public function __construct( |
|
| 48 | Mqtt\Connection $connection, |
|
| 49 | Client\IClient $client |
|
| 50 | ) { |
|
| 51 | $this->connection = $connection; |
|
| 52 | $this->client = $client; |
|
| 53 | } |
|
| 54 | ||
| 55 | /** |
|
| 56 | * @return Mqtt\Connection |
|
| 57 | */ |
|
| 58 | public function getConnection() : Mqtt\Connection |
|
| 59 | { |
|
| 60 | return $this->connection; |
|
| 61 | } |
|
| 62 | ||
| 63 | /** |
|
| 64 | * @return Client\IClient |
|
| 65 | */ |
|
| 66 | public function getClient() : Client\IClient |
|
| 67 | { |
|
| 68 | return $this->client; |
|
| 69 | } |
|
| 70 | } |
|
| 71 | ||