You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
1.2KB

  1. <?php
  2. namespace common\logic\Product\ProductPrice\Module;
  3. use common\logic\AbstractModule;
  4. use common\logic\Product\ProductPrice\Repository\ProductPriceRepository;
  5. use common\logic\Product\ProductPrice\Service\ProductPriceBuilder;
  6. use common\logic\Product\ProductPrice\Service\ProductPriceDefinition;
  7. use common\logic\Product\ProductPrice\Service\ProductPriceSolver;
  8. /**
  9. * @mixin ProductPriceDefinition
  10. * @mixin ProductPriceRepository
  11. * @mixin ProductPriceBuilder
  12. */
  13. class ProductPriceModule extends AbstractModule
  14. {
  15. public function getServices(): array
  16. {
  17. return [
  18. ProductPriceDefinition::class,
  19. ProductPriceSolver::class,
  20. ProductPriceBuilder::class,
  21. ProductPriceRepository::class
  22. ];
  23. }
  24. public function getDefinition(): ProductPriceDefinition
  25. {
  26. return ProductPriceDefinition::getInstance();
  27. }
  28. public function getBuilder(): ProductPriceBuilder
  29. {
  30. return ProductPriceBuilder::getInstance();
  31. }
  32. public function getSolver(): ProductPriceSolver
  33. {
  34. return ProductPriceSolver::getInstance();
  35. }
  36. public function getRepository(): ProductPriceRepository
  37. {
  38. return ProductPriceRepository::getInstance();
  39. }
  40. }