it.geosolutions.geobatch.flow.event.generator.file
Class FileBasedEventGenerator<T extends java.util.EventObject>

java.lang.Object
  extended by it.geosolutions.geobatch.catalog.impl.BaseIdentifiable
      extended by it.geosolutions.geobatch.flow.event.generator.BaseEventGenerator<T>
          extended by it.geosolutions.geobatch.flow.event.generator.file.FileBasedEventGenerator<T>
All Implemented Interfaces:
Identifiable, EventGenerator<T>, java.lang.Cloneable

public class FileBasedEventGenerator<T extends java.util.EventObject>
extends BaseEventGenerator<T>

Author:
AlFa (Alessio Fabiani), (r2) Carlo Cancellieri - carlo.cancellieri@geo-solutions.it

Constructor Summary
FileBasedEventGenerator(FileBasedEventGeneratorConfiguration configuration)
          Constructor
 
Method Summary
 void addListener(FlowEventListener<T> fileListener)
          Add listener to this file monitor.
 void dispose()
           
 boolean equals(java.lang.Object obj)
           
 FileSystemEventType getEventType()
           
 java.io.File getWatchDirectory()
           
 java.lang.String getWildCard()
           
 int hashCode()
           
 boolean isRunning()
           
 void pause()
           
 void removeListener(FlowEventListener<T> fileListener)
          Remove listener from this file monitor.
 void start()
           
 void stop()
           
 java.lang.String toString()
           
 
Methods inherited from class it.geosolutions.geobatch.catalog.impl.BaseIdentifiable
clone, getDescription, getId, getName, setDescription, setId, setName
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FileBasedEventGenerator

public FileBasedEventGenerator(FileBasedEventGeneratorConfiguration configuration)
                        throws java.io.IOException,
                               java.lang.NullPointerException
Constructor

Parameters:
configuration - the FileBasedEventGeneratorConfiguration configuration
Throws:
java.io.IOException - see initialize
java.lang.NullPointerException
Method Detail

getWatchDirectory

public java.io.File getWatchDirectory()
Returns:
the watchDirectory

getWildCard

public java.lang.String getWildCard()
Returns:
the wildCard

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

dispose

public void dispose()
See Also:
Monitor

isRunning

public boolean isRunning()
Returns:
See Also:
Monitor

start

public void start()
See Also:
Monitor

stop

public void stop()
See Also:
Monitor

pause

public void pause()

addListener

public void addListener(FlowEventListener<T> fileListener)
Add listener to this file monitor.

Parameters:
fileListener - Listener to add.

removeListener

public void removeListener(FlowEventListener<T> fileListener)
Remove listener from this file monitor.

Parameters:
fileListener - Listener to remove.

getEventType

public FileSystemEventType getEventType()
Returns:
the acceptedEvent


Copyright © 2008-2012 GeoSolutions. All Rights Reserved.