vendor/payum/core/Payum/Core/Payum.php line 70

Open in your IDE?
  1. <?php
  2. namespace Payum\Core;
  3. use Payum\Core\Registry\RegistryInterface;
  4. use Payum\Core\Security\GenericTokenFactoryInterface;
  5. use Payum\Core\Security\HttpRequestVerifierInterface;
  6. use Payum\Core\Storage\StorageInterface;
  7. class Payum implements RegistryInterface
  8. {
  9.     /**
  10.      * @var RegistryInterface
  11.      */
  12.     protected $registry;
  13.     /**
  14.      * @var HttpRequestVerifierInterface
  15.      */
  16.     protected $httpRequestVerifier;
  17.     /**
  18.      * @var GenericTokenFactoryInterface
  19.      */
  20.     protected $tokenFactory;
  21.     /**
  22.      * @var StorageInterface
  23.      */
  24.     protected $tokenStorage;
  25.     /**
  26.      * @param RegistryInterface            $registry
  27.      * @param HttpRequestVerifierInterface $httpRequestVerifier
  28.      * @param GenericTokenFactoryInterface $tokenFactory
  29.      * @param StorageInterface             $tokenStorage
  30.      */
  31.     public function __construct(
  32.         RegistryInterface $registry,
  33.         HttpRequestVerifierInterface $httpRequestVerifier,
  34.         GenericTokenFactoryInterface $tokenFactory,
  35.         StorageInterface $tokenStorage
  36.     ) {
  37.         $this->registry = $registry;
  38.         $this->httpRequestVerifier = $httpRequestVerifier;
  39.         $this->tokenFactory = $tokenFactory;
  40.         $this->tokenStorage = $tokenStorage;
  41.     }
  42.     /**
  43.      * {@inheritDoc}
  44.      */
  45.     public function getGatewayFactory($name)
  46.     {
  47.         return $this->registry->getGatewayFactory($name);
  48.     }
  49.     /**
  50.      * {@inheritDoc}
  51.      */
  52.     public function getGatewayFactories()
  53.     {
  54.         return $this->registry->getGatewayFactories();
  55.     }
  56.     /**
  57.      * {@inheritDoc}
  58.      */
  59.     public function getGateway($name)
  60.     {
  61.         return $this->registry->getGateway($name);
  62.     }
  63.     /**
  64.      * {@inheritDoc}
  65.      */
  66.     public function getGateways()
  67.     {
  68.         return $this->registry->getGateways();
  69.     }
  70.     /**
  71.      * {@inheritDoc}
  72.      */
  73.     public function getStorage($class)
  74.     {
  75.         return $this->registry->getStorage($class);
  76.     }
  77.     /**
  78.      * {@inheritDoc}
  79.      */
  80.     public function getStorages()
  81.     {
  82.         return $this->registry->getStorages();
  83.     }
  84.     /**
  85.      * @return HttpRequestVerifierInterface
  86.      */
  87.     public function getHttpRequestVerifier()
  88.     {
  89.         return $this->httpRequestVerifier;
  90.     }
  91.     /**
  92.      * @return GenericTokenFactoryInterface
  93.      */
  94.     public function getTokenFactory()
  95.     {
  96.         return $this->tokenFactory;
  97.     }
  98.     /**
  99.      * @return StorageInterface
  100.      */
  101.     public function getTokenStorage()
  102.     {
  103.         return $this->tokenStorage;
  104.     }
  105. }