vendor/shopware/core/System/Unit/UnitEntity.php line 11

  1. <?php declare(strict_types=1);
  2. namespace Shopware\Core\System\Unit;
  3. use Shopware\Core\Content\Product\ProductCollection;
  4. use Shopware\Core\Framework\DataAbstractionLayer\Entity;
  5. use Shopware\Core\Framework\DataAbstractionLayer\EntityCustomFieldsTrait;
  6. use Shopware\Core\Framework\DataAbstractionLayer\EntityIdTrait;
  7. use Shopware\Core\Framework\Log\Package;
  8. use Shopware\Core\System\Unit\Aggregate\UnitTranslation\UnitTranslationCollection;
  9. #[Package('inventory')]
  10. class UnitEntity extends Entity
  11. {
  12.     use EntityCustomFieldsTrait;
  13.     use EntityIdTrait;
  14.     /**
  15.      * @var string|null
  16.      */
  17.     protected $shortCode;
  18.     /**
  19.      * @var string|null
  20.      */
  21.     protected $name;
  22.     /**
  23.      * @var UnitTranslationCollection|null
  24.      */
  25.     protected $translations;
  26.     /**
  27.      * @var ProductCollection|null
  28.      */
  29.     protected $products;
  30.     public function getShortCode(): ?string
  31.     {
  32.         return $this->shortCode;
  33.     }
  34.     public function setShortCode(?string $shortCode): void
  35.     {
  36.         $this->shortCode $shortCode;
  37.     }
  38.     public function getName(): ?string
  39.     {
  40.         return $this->name;
  41.     }
  42.     public function setName(?string $name): void
  43.     {
  44.         $this->name $name;
  45.     }
  46.     public function getTranslations(): ?UnitTranslationCollection
  47.     {
  48.         return $this->translations;
  49.     }
  50.     public function setTranslations(UnitTranslationCollection $translations): void
  51.     {
  52.         $this->translations $translations;
  53.     }
  54.     public function getProducts(): ?ProductCollection
  55.     {
  56.         return $this->products;
  57.     }
  58.     public function setProducts(ProductCollection $products): void
  59.     {
  60.         $this->products $products;
  61.     }
  62. }