org.krakenapps.filter
Class ActiveFilter

java.lang.Object
  extended by org.krakenapps.filter.DefaultFilter
      extended by org.krakenapps.filter.ActiveFilter
All Implemented Interfaces:
Filter

public abstract class ActiveFilter
extends DefaultFilter

ActiveFilter class should be implemented by any filter class which filters are intended to be excuted by a thread.

Since:
1.0.0
Author:
xeraph
See Also:
Filter

Constructor Summary
ActiveFilter()
           
 
Method Summary
 void close()
          Finalize callback.
 boolean isRunning()
          Returns true if thread is running.
 void open()
          Initialize callback.
abstract  void run()
          ActiveFilterRunner calls this callback in each loop.
 void setRunning(boolean isRunning)
           
 
Methods inherited from class org.krakenapps.filter.DefaultFilter
getInputMessageSpecs, getOutputMessageSpec, getProperty, getPropertyKeys, process, setProperty, unsetProperty, validateConfiguration
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ActiveFilter

public ActiveFilter()
Method Detail

isRunning

public boolean isRunning()
Returns true if thread is running.

Returns:
true if thread is running

setRunning

public void setRunning(boolean isRunning)

open

public void open()
          throws ConfigurationException
Initialize callback. ActiveFilterRunner calls this method before the run loop. Override this.

Throws:
ConfigurationException - if failed to configure

close

public void close()
Finalize callback. ActiveFilterRunner calls this method after the run loop. Override this.


run

public abstract void run()
                  throws java.lang.InterruptedException
ActiveFilterRunner calls this callback in each loop. Thread will sleep some milliseconds after run.

Throws:
java.lang.InterruptedException - if thread is interrupted


Copyright © 2008-2009 Kraken Project. All Rights Reserved.