Class FileProcessor

    • Field Detail

      • m_Actors

        protected Sequence m_Actors
        the flow items.
      • m_UseFiles

        protected boolean m_UseFiles
        whether to use files or strings as input for the actors.
      • m_Input

        protected transient Actor m_Input
        the actor to use for input.
    • Constructor Detail

      • FileProcessor

        public FileProcessor()
    • Method Detail

      • reset

        protected void reset()
        Resets the actor.
        Overrides:
        reset in class AbstractActor
      • updateParent

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

        protected String checkSubActor​(int index,
                                       Actor actor)
        Checks the tee actor before it is set. Returns an error message if the actor is not acceptable, null otherwise.
        Parameters:
        index - the index the actor gets set
        actor - the actor to check
        Returns:
        null if accepted, otherwise error message
      • checkSubActors

        protected String checkSubActors​(Actor[] actors)
        Checks the tee actors before they are set via the setTeeActors method. Returns an error message if the actors are not acceptable, null otherwise.
        Parameters:
        actors - the actors to check
        Returns:
        null if accepted, otherwise error message
      • setActors

        public void setActors​(Actor[] value)
        Sets the actor to tee-off to.
        Parameters:
        value - the actor
      • getActors

        public Actor[] getActors()
        Returns the actors to tee-off to.
        Returns:
        the actors
      • actorsTipText

        public 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.
      • 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
      • 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()
        Description copied from interface: ActorHandler
        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 successful, otherwise error message
      • 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
      • generates

        public Class[] generates()
        Returns the class of objects that it generates.
        Specified by:
        generates in interface OutputProducer
        Returns:
        the Class of the generated tokens
      • 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 successful, otherwise error message
      • 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 successful, otherwise error message
      • 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
      • setUpSubActors

        protected String setUpSubActors()
        Performs the setUp of the sub-actors.
        Returns:
        null if everything is fine, otherwise error message