src/MenuItem/SplitItem.php
public function getSelectedItem() : MenuItemInterface
    {
        if (null === $this->selectedItemIndex) {
            throw new \RuntimeException('No item is selected');
        }
        
        return $this->items[$this->selectedItemIndex];
    }
public function getSelectedItem() : MenuItemInterface
    {
        if (null === $this->selectedItemIndex) {
            throw new \RuntimeException('No item is selected');
        }
        
        return $this->items[$this->selectedItemIndex];
    }
Get the currently selected item - if no items are selectable
then throw an exception.