選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

PaymentModule.php 1.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. <?php
  2. namespace common\logic\Payment\Module;
  3. use common\logic\AbstractModule;
  4. use common\logic\Payment\Repository\PaymentRepository;
  5. use common\logic\Payment\Service\PaymentNotifier;
  6. use common\logic\Payment\Service\PaymentManager;
  7. use common\logic\Payment\Service\PaymentBuilder;
  8. use common\logic\Payment\Service\PaymentDefinition;
  9. use common\logic\Payment\Service\PaymentSolver;
  10. /**
  11. * @mixin PaymentDefinition
  12. * @mixin PaymentSolver
  13. * @mixin PaymentRepository
  14. * @mixin PaymentBuilder
  15. * @mixin PaymentManager
  16. */
  17. class PaymentModule extends AbstractModule
  18. {
  19. public function getServices(): array
  20. {
  21. return [
  22. PaymentDefinition::class,
  23. PaymentSolver::class,
  24. PaymentBuilder::class,
  25. PaymentRepository::class,
  26. PaymentNotifier::class,
  27. PaymentManager::class,
  28. ];
  29. }
  30. public function getDefinition(): PaymentDefinition
  31. {
  32. return PaymentDefinition::getInstance();
  33. }
  34. public function getSolver(): PaymentSolver
  35. {
  36. return PaymentSolver::getInstance();
  37. }
  38. public function getBuilder(): PaymentBuilder
  39. {
  40. return PaymentBuilder::getInstance();
  41. }
  42. public function getRepository(): PaymentRepository
  43. {
  44. return PaymentRepository::getInstance();
  45. }
  46. public function getNotifier(): PaymentNotifier
  47. {
  48. return PaymentNotifier::getInstance();
  49. }
  50. public function getManager(): PaymentManager
  51. {
  52. return PaymentManager::getInstance();
  53. }
  54. }