package be.iminds.ilabt.jfed.experimenter_gui.slice;

import be.iminds.ilabt.jfed.experimenter_gui.slice.ribbon_tabs.ControlViewerRibbonTab;
import be.iminds.ilabt.jfed.experimenter_gui.slice.ribbon_tabs.RspecViewerRibbonTab;
import be.iminds.ilabt.jfed.experimenter_gui.slice.ribbon_tabs.SliceRibbonTab;
import be.iminds.ilabt.jfed.experimenter_gui.slice.ribbon_tabs.TopologyViewerRibbonTab;
import com.google.common.eventbus.EventBus;

import javax.inject.Inject;
import java.util.ArrayList;
import java.util.List;

/**
 * SliceRibbonTabs
 */
public class SliceRibbonTabs {
    private final List<SliceRibbonTab> ribbonTabs;
    private final TopologyViewerRibbonTab topologyViewerRibbonTab;
    private final RspecViewerRibbonTab rspecViewerRibbonTab;
    private final ControlViewerRibbonTab controlViewerRibbonTab;

    @Inject
    public SliceRibbonTabs(EventBus eventBus) {
        ribbonTabs = new ArrayList<>();
        rspecViewerRibbonTab = new RspecViewerRibbonTab(eventBus);
        topologyViewerRibbonTab = new TopologyViewerRibbonTab(eventBus);
        controlViewerRibbonTab = new ControlViewerRibbonTab(eventBus);

        ribbonTabs.add(topologyViewerRibbonTab);
        ribbonTabs.add(rspecViewerRibbonTab);
        ribbonTabs.add(controlViewerRibbonTab);
    }

    public List<? extends SliceRibbonTab> getRibbonTabs() {
        return ribbonTabs;
    }

    public TopologyViewerRibbonTab getTopologyViewerRibbonTab() {
        return topologyViewerRibbonTab;
    }

    public RspecViewerRibbonTab getRspecViewerRibbonTab() {
        return rspecViewerRibbonTab;
    }

    public ControlViewerRibbonTab getControlViewerRibbonTab() {
        return controlViewerRibbonTab;
    }
}
