void (@NotNull String tabID) { SETab selectedTab = myHeader.getTabs().stream() .filter(tab -> tab.getID().equals(tabID)) .findAny() .orElseThrow(() -> new IllegalArgumentException(String.format("There is no such tab - %s", tabID))); switchToTab(selectedTab); }