vendor/store.shopware.com/swpgoogletranslatesix/src/SwpGoogleTranslateSix.php line 24

Open in your IDE?
  1. <?php declare(strict_types=1);
  2. /**
  3.  * Shopware
  4.  * Copyright © 2020
  5.  *
  6.  * @category   Shopware
  7.  * @package    SwpGoogleTranslateSix
  8.  * @subpackage SwpGoogleTranslateSix.php
  9.  *
  10.  * @copyright  2020 Iguana-Labs GmbH
  11.  * @author     Module Factory <info at module-factory.com>
  12.  * @license    https://www.module-factory.com/eula
  13.  */
  14. namespace Swp\GoogleTranslateSix;
  15. use Shopware\Core\Framework\Plugin;
  16. use Shopware\Core\Framework\Plugin\Context\ActivateContext;
  17. use Shopware\Core\Framework\Plugin\Context\DeactivateContext;
  18. use Shopware\Core\Framework\Plugin\Context\InstallContext;
  19. use Shopware\Core\Framework\Plugin\Context\UninstallContext;
  20. use Swp\GoogleTranslateSix\Utils\InstallUninstall;
  21. class SwpGoogleTranslateSix extends Plugin
  22. {
  23.     public function install(InstallContext $installContext): void
  24.     {
  25.         parent::install($installContext);
  26.         (new InstallUninstall($this->container))->install($installContext->getContext());
  27.     }
  28.     public function uninstall(UninstallContext $uninstallContext): void
  29.     {
  30.         parent::uninstall($uninstallContext);
  31.         if ($uninstallContext->keepUserData()) {
  32.             return;
  33.         }
  34.         (new InstallUninstall($this->container))->uninstall($uninstallContext->getContext());
  35.     }
  36.     public function activate(ActivateContext $activateContext): void
  37.     {
  38.         parent::activate($activateContext);
  39.     }
  40.     public function deactivate(DeactivateContext $deactivateContext): void
  41.     {
  42.         parent::deactivate($deactivateContext);
  43.     }
  44. }