Class AbstractMultiView

    • Field Detail

      • m_Actors

        protected List<Actor> m_Actors
        the underlying display actors.
      • m_ShowFlowControlSubMenu

        protected boolean m_ShowFlowControlSubMenu
        whether to show flow control sub-menu.
      • m_MenuBar

        protected JMenuBar m_MenuBar
        the menu bar, if used.
      • m_MenuItemFileClear

        protected JMenuItem m_MenuItemFileClear
        the "clear" menu item.
      • m_MenuItemFileClose

        protected JMenuItem m_MenuItemFileClose
        the "exit" menu item.
      • m_MenuItemFlowPauseResume

        protected JMenuItem m_MenuItemFlowPauseResume
        the "pause/resume" menu item.
      • m_MenuItemFlowStop

        protected JMenuItem m_MenuItemFlowStop
        the "stop" menu item.
    • Constructor Detail

      • AbstractMultiView

        public AbstractMultiView()
    • Method Detail

      • setActors

        public void setActors​(Actor[] value)
        Sets the panel providers.
        Parameters:
        value - the panel providers
      • getActors

        public Actor[] getActors()
        Returns the panel providers.
        Returns:
        the panel providers
      • actorsTipText

        public abstract String actorsTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • setShowFlowControlSubMenu

        public void setShowFlowControlSubMenu​(boolean value)
        Sets whether to show a flow control sub-menu in the menubar.
        Parameters:
        value - true if to show
      • getShowFlowControlSubMenu

        public boolean getShowFlowControlSubMenu()
        Returns whether to show a flow control sub-menu in the menubar.
        Returns:
        true if to show
      • showFlowControlSubMenuTipText

        public String showFlowControlSubMenuTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • check

        protected String check​(Actor actor)
        Checks whether the actor is valid.
        Parameters:
        actor - the actor to check
        Returns:
        null if OK, otherwise error message
      • updateParent

        protected void updateParent()
        Updates the parent of all actors in this group.
      • add

        public String add​(Actor actor)
        Inserts the actor at the end.
        Specified by:
        add in interface MutableActorHandler
        Parameters:
        actor - the actor to insert
        Returns:
        null if everything is fine, otherwise the error
      • add

        public String add​(int index,
                          Actor actor)
        Inserts the actor at the given position.
        Specified by:
        add in interface MutableActorHandler
        Parameters:
        index - the position
        actor - the actor to insert
        Returns:
        null if everything is fine, otherwise the error
      • remove

        public Actor remove​(int index)
        Removes the actor at the given position and returns the removed object.
        Specified by:
        remove in interface MutableActorHandler
        Parameters:
        index - the position
        Returns:
        the removed actor
      • getActorHandlerInfo

        public ActorHandlerInfo getActorHandlerInfo()
        Returns some information about the actor handler, e.g., whether it can contain standalones and the actor execution.
        Specified by:
        getActorHandlerInfo in interface ActorHandler
        Returns:
        the info
      • isReferencingRequired

        public boolean isReferencingRequired()
        Returns whether actors have to be referenced elsewhere in the flow or whether it is optional.
        Specified by:
        isReferencingRequired in interface ActorReferenceHandler
        Returns:
        true if required, false if optional
      • check

        public String check()
        Performs checks on the "sub-actors".
        Specified by:
        check in interface ActorHandler
        Returns:
        null if everything is fine, otherwise the error
      • size

        public int size()
        Returns the size of the group.
        Specified by:
        size in interface ActorHandler
        Returns:
        the size
      • get

        public Actor get​(int index)
        Returns the actor at the given position.
        Specified by:
        get in interface ActorHandler
        Parameters:
        index - the position
        Returns:
        the actor
      • set

        public String set​(int index,
                          Actor actor)
        Sets the actor at the given position.
        Specified by:
        set in interface ActorHandler
        Parameters:
        index - the position
        actor - the actor to set at this position
        Returns:
        null if everything is fine, otherwise the error
      • indexOf

        public int indexOf​(String actor)
        Returns the index of the actor.
        Specified by:
        indexOf in interface ActorHandler
        Parameters:
        actor - the name of the actor to look for
        Returns:
        the index of -1 if not found
      • firstActive

        public Actor firstActive()
        Returns the first non-skipped actor.
        Specified by:
        firstActive in interface ActorHandler
        Returns:
        the first 'active' actor, null if none available
      • lastActive

        public Actor lastActive()
        Returns the last non-skipped actor.
        Specified by:
        lastActive in interface ActorHandler
        Returns:
        the last 'active' actor, null if none available
      • makeVisible

        public abstract boolean makeVisible​(AbstractMultiView.ViewWrapper wrapper)
        Ensures that the wrapper is visible.
        Parameters:
        wrapper - the wrapper to make visible
        Returns:
        true if successful
      • newPanel

        protected abstract BasePanel newPanel()
        Creates the panel to display in the dialog.
        Specified by:
        newPanel in class AbstractDisplay
        Returns:
        the panel
      • setUp

        public String setUp()
        Initializes the item for flow execution. Also calls the reset() method first before anything else.
        Specified by:
        setUp in interface Actor
        Overrides:
        setUp in class AbstractActor
        Returns:
        null if everything is fine, otherwise error message
        See Also:
        AbstractDisplay.reset()
      • doExecute

        protected String doExecute()
        Executes the flow item.
        Overrides:
        doExecute in class AbstractDisplay
        Returns:
        null if everything is fine, otherwise error message
      • addPanel

        public abstract void addPanel​(Actor actor,
                                      BasePanel panel)
        Replaces the current dummy panel with the actual panel.
        Parameters:
        actor - the actor this panel is for
        panel - the panel to replace the dummy one
      • wrapUp

        public void wrapUp()
        Cleans up after the execution has finished.
        Specified by:
        wrapUp in interface Actor
        Overrides:
        wrapUp in class AbstractDisplay
      • createMenuBar

        protected JMenuBar createMenuBar()
        Assembles the menu bar.
        Returns:
        the menu bar
      • getMenuBar

        public JMenuBar getMenuBar()
        Creates a menu bar (singleton per panel object). Can be used in frames.
        Specified by:
        getMenuBar in interface MenuBarProvider
        Returns:
        the menu bar
      • updateMenu

        protected void updateMenu()
        updates the enabled state of the menu items.
      • supportsClear

        protected boolean supportsClear()
        Whether "clear" is supported and shows up in the menu.
        Returns:
        true if supported by at least one wrapped view
      • clear

        protected void clear()
        Clears the display, if possible.
      • close

        protected void close()
        Closes the dialog or frame.
      • canPauseOrResume

        protected boolean canPauseOrResume()
        Returns whether the flow can be paused/resumed.
        Returns:
        true if pause/resume available
      • isPaused

        protected boolean isPaused()
        Returns whether the flow is currently paused.
        Returns:
        true if currently paused
      • pauseResumeFlow

        protected void pauseResumeFlow()
        Pauses or resumes the flow.
      • stopFlow

        protected void stopFlow()
        Stops the flow.
      • hasSendToItem

        public boolean hasSendToItem​(Class[] cls)
        Checks whether something to send is available.
        Specified by:
        hasSendToItem in interface SendToActionSupporter
        Parameters:
        cls - the requested classes
        Returns:
        true if an object is available for sending