class SwitchViewControl extends Composite {

    void configureButton(final Button button,
                         final String iconType,
                         final boolean selected,
                         final Tooltip tooltip,
                         final String tooltipText,
                         final Button otherButton,
                         final Runnable handler) {
        button.setSize(ButtonSize.DEFAULT);
        button.setType(selected ? ButtonType.INFO : ButtonType.LINK);

        button.setIcon(IconType.valueOf(iconType));
        button.setIconFixedWidth(true);
        button.setIconSize(IconSize.LARGE);
        button.setIconPosition(IconPosition.LEFT);

        tooltip.setTitle(tooltipText);
        tooltip.setContainer("body");
        tooltip.setPlacement(Placement.AUTO);

        button.addClickHandler(event -> {
            select(button);
            deselect(otherButton);
            handler.run();
        });
    }

      SwitchViewControl(final String caseViewIconType,
                      final String caseViewTooltipText,
                      final Runnable caseViewSwitchHandler,
                      final String processViewIconType,
                      final String processViewTooltipText,
                      final Runnable processViewSwitchHandler);

}