| Conditions | 3 |
| Paths | 4 |
| Total Lines | 18 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 26 | public function createNewWithValues( |
||
| 27 | int $position, |
||
| 28 | bool $isPresentationSlot = false, |
||
| 29 | array $additionalOptions = [] |
||
| 30 | ): ProductBundleSlotOptionsInterface { |
||
| 31 | $productBundleSlotOptions = $this->createNew(); |
||
| 32 | $productBundleSlotOptions->setPosition($position); |
||
| 33 | |||
| 34 | if ($isPresentationSlot) { |
||
| 35 | $productBundleSlotOptions->setAsPresentationSlot(); |
||
| 36 | } |
||
| 37 | |||
| 38 | foreach ($additionalOptions as $name => $value) { |
||
| 39 | $productBundleSlotOptions->addOption($name, $value); |
||
| 40 | } |
||
| 41 | |||
| 42 | return $productBundleSlotOptions; |
||
| 43 | } |
||
| 44 | } |
||
| 45 |