it.geosolutions.geobatch.flow.event.action
Interface Action<XEO extends java.util.EventObject>

Type Parameters:
XEO -
All Superinterfaces:
Identifiable, Job, ListenerRegistry<ProgressListener>
All Known Implementing Classes:
BaseAction

public interface Action<XEO extends java.util.EventObject>
extends Identifiable, Job, ListenerRegistry<ProgressListener>

Takes a queue of events, process them (execute(Queue events)) and provides a new queue of event to be processed by the next Action.

(WIP) Will also provide ways to monitor whether the Action is currently running, which Event is running

Author:
Simone Giannecchini, GeoSolutions

Method Summary
 void destroy()
           
 java.util.Queue<XEO> execute(java.util.Queue<XEO> events)
           
 boolean isFailIgnored()
          Tells if an exception in this Actions should not break the entire flow.
 
Methods inherited from interface it.geosolutions.geobatch.catalog.Identifiable
getDescription, getId, getName, setDescription, setId, setName
 
Methods inherited from interface it.geosolutions.geobatch.flow.Job
isPaused, pause, pause, resume
 
Methods inherited from interface it.geosolutions.geobatch.misc.ListenerRegistry
addListener, removeListener
 

Method Detail

execute

java.util.Queue<XEO> execute(java.util.Queue<XEO> events)
                                                           throws ActionException
Throws:
ActionException

destroy

void destroy()

isFailIgnored

boolean isFailIgnored()
Tells if an exception in this Actions should not break the entire flow.
Defaults to false.

Some somehow "minor" actions would not break the logical flow, for instance a remote file deletion via FTP.

Returns:
true if an error in this Actions should not stop the whole flow.


Copyright © 2008-2012 GeoSolutions. All Rights Reserved.