This repository has been archived by the owner on Feb 17, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Added symfony events
- Loading branch information
Showing
19 changed files
with
569 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
<?php | ||
/** | ||
* DisableEvent.php | ||
* | ||
* @copyright More in license.md | ||
* @license https://www.ipublikuj.eu | ||
* @author Adam Kadlec <[email protected]> | ||
* @package iPublikuj:Packages! | ||
* @subpackage Events | ||
* @since 1.0.0 | ||
* | ||
* @date 15.11.19 | ||
*/ | ||
|
||
namespace IPub\Packages\Events; | ||
|
||
use Symfony\Contracts\EventDispatcher; | ||
|
||
use IPub\Packages; | ||
use IPub\Packages\Entities; | ||
|
||
/** | ||
* Package disabled event | ||
* | ||
* @package iPublikuj:Packages! | ||
* @subpackage Events | ||
* | ||
* @author Adam Kadlec <[email protected]> | ||
*/ | ||
final class DisableEvent extends EventDispatcher\Event | ||
{ | ||
/** | ||
* @var Packages\PackagesManager | ||
*/ | ||
private $manager; | ||
|
||
/** | ||
* @var Entities\IPackage | ||
*/ | ||
private $package; | ||
|
||
/** | ||
* @param Packages\PackagesManager $manager | ||
* @param Entities\IPackage $package | ||
*/ | ||
public function __construct( | ||
Packages\PackagesManager $manager, | ||
Entities\IPackage $package | ||
) { | ||
$this->manager = $manager; | ||
$this->package = $package; | ||
} | ||
|
||
/** | ||
* @return Packages\PackagesManager | ||
*/ | ||
public function getManager() : Packages\PackagesManager | ||
{ | ||
return $this->manager; | ||
} | ||
|
||
/** | ||
* @return Entities\IPackage | ||
*/ | ||
public function getPackage() : Entities\IPackage | ||
{ | ||
return $this->package; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
<?php | ||
/** | ||
* EnableEvent.php | ||
* | ||
* @copyright More in license.md | ||
* @license https://www.ipublikuj.eu | ||
* @author Adam Kadlec <[email protected]> | ||
* @package iPublikuj:Packages! | ||
* @subpackage Events | ||
* @since 1.0.0 | ||
* | ||
* @date 15.11.19 | ||
*/ | ||
|
||
namespace IPub\Packages\Events; | ||
|
||
use Symfony\Contracts\EventDispatcher; | ||
|
||
use IPub\Packages; | ||
use IPub\Packages\Entities; | ||
|
||
/** | ||
* Package enabled event | ||
* | ||
* @package iPublikuj:Packages! | ||
* @subpackage Events | ||
* | ||
* @author Adam Kadlec <[email protected]> | ||
*/ | ||
final class EnableEvent extends EventDispatcher\Event | ||
{ | ||
/** | ||
* @var Packages\PackagesManager | ||
*/ | ||
private $manager; | ||
|
||
/** | ||
* @var Entities\IPackage | ||
*/ | ||
private $package; | ||
|
||
/** | ||
* @param Packages\PackagesManager $manager | ||
* @param Entities\IPackage $package | ||
*/ | ||
public function __construct( | ||
Packages\PackagesManager $manager, | ||
Entities\IPackage $package | ||
) { | ||
$this->manager = $manager; | ||
$this->package = $package; | ||
} | ||
|
||
/** | ||
* @return Packages\PackagesManager | ||
*/ | ||
public function getManager() : Packages\PackagesManager | ||
{ | ||
return $this->manager; | ||
} | ||
|
||
/** | ||
* @return Entities\IPackage | ||
*/ | ||
public function getPackage() : Entities\IPackage | ||
{ | ||
return $this->package; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
<?php | ||
/** | ||
* InstallEvent.php | ||
* | ||
* @copyright More in license.md | ||
* @license https://www.ipublikuj.eu | ||
* @author Adam Kadlec <[email protected]> | ||
* @package iPublikuj:Packages! | ||
* @subpackage Events | ||
* @since 1.0.0 | ||
* | ||
* @date 15.11.19 | ||
*/ | ||
|
||
namespace IPub\Packages\Events; | ||
|
||
use Symfony\Contracts\EventDispatcher; | ||
|
||
use IPub\Packages; | ||
use IPub\Packages\Entities; | ||
|
||
/** | ||
* Package installed event | ||
* | ||
* @package iPublikuj:Packages! | ||
* @subpackage Events | ||
* | ||
* @author Adam Kadlec <[email protected]> | ||
*/ | ||
final class InstallEvent extends EventDispatcher\Event | ||
{ | ||
/** | ||
* @var Packages\PackagesManager | ||
*/ | ||
private $manager; | ||
|
||
/** | ||
* @var Entities\IPackage | ||
*/ | ||
private $package; | ||
|
||
/** | ||
* @param Packages\PackagesManager $manager | ||
* @param Entities\IPackage $package | ||
*/ | ||
public function __construct( | ||
Packages\PackagesManager $manager, | ||
Entities\IPackage $package | ||
) { | ||
$this->manager = $manager; | ||
$this->package = $package; | ||
} | ||
|
||
/** | ||
* @return Packages\PackagesManager | ||
*/ | ||
public function getManager() : Packages\PackagesManager | ||
{ | ||
return $this->manager; | ||
} | ||
|
||
/** | ||
* @return Entities\IPackage | ||
*/ | ||
public function getPackage() : Entities\IPackage | ||
{ | ||
return $this->package; | ||
} | ||
} |
Oops, something went wrong.