| Total Complexity | 10 |
| Total Lines | 60 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 18 | class WishlistProduct implements WishlistProductInterface |
||
| 19 | { |
||
| 20 | protected ?int $id; |
||
| 21 | |||
| 22 | protected WishlistInterface $wishlist; |
||
| 23 | |||
| 24 | protected ?ProductInterface $product; |
||
| 25 | |||
| 26 | protected ?ProductVariantInterface $variant; |
||
| 27 | |||
| 28 | protected int $quantity = 0; |
||
| 29 | |||
| 30 | public function __construct() |
||
| 31 | { |
||
| 32 | $this->id = null; |
||
| 33 | } |
||
| 34 | |||
| 35 | public function getId(): ?int |
||
| 36 | { |
||
| 37 | return $this->id; |
||
| 38 | } |
||
| 39 | |||
| 40 | public function getWishlist(): WishlistInterface |
||
| 43 | } |
||
| 44 | |||
| 45 | public function setWishlist(WishlistInterface $wishlist): void |
||
| 46 | { |
||
| 47 | $this->wishlist = $wishlist; |
||
| 48 | } |
||
| 49 | |||
| 50 | public function getProduct(): ProductInterface |
||
| 51 | { |
||
| 52 | return $this->product; |
||
|
|
|||
| 53 | } |
||
| 54 | |||
| 55 | public function setProduct(ProductInterface $product): void |
||
| 56 | { |
||
| 57 | $this->product = $product; |
||
| 58 | } |
||
| 59 | |||
| 60 | public function getVariant(): ?ProductVariantInterface |
||
| 61 | { |
||
| 62 | return $this->variant; |
||
| 63 | } |
||
| 64 | |||
| 65 | public function setVariant(?ProductVariantInterface $variant): void |
||
| 66 | { |
||
| 67 | $this->variant = $variant; |
||
| 68 | } |
||
| 69 | |||
| 70 | public function getQuantity(): int |
||
| 73 | } |
||
| 74 | |||
| 75 | public function setQuantity(int $quantity): void |
||
| 76 | { |
||
| 77 | $this->quantity = $quantity; |
||
| 78 | } |
||
| 79 | } |
||
| 80 |