nl.knowledgeplaza.util
Class ProgressListener

java.lang.Object
  extended by nl.knowledgeplaza.util.ProgressListener

public abstract class ProgressListener
extends java.lang.Object

A class to provide progress feedback. The class does not dictate what the listened to process will provide for feedback. It may or may not class begin, done or init. That depends on the implementation in the process that is monitored. Progress is called always, but it is undefined how often, that -again- depends on the implementation in the process that is monitored. An actual progress listener should extend this class. It can override the neccesary methods and do with the information what is appropriate for the context. For example: - the information can be printed on System.out - in a Swing application the information can be forwarded to a MonitorProgress component. This is implemented as a abstract class and not an interface, so that future changes will not required existing code to be modified.


Constructor Summary
ProgressListener()
           
 
Method Summary
 void begin()
           
 void done()
           
 void init(long min, long max)
           
abstract  void progress(long current, java.lang.String info)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProgressListener

public ProgressListener()
Method Detail

init

public void init(long min,
                 long max)

begin

public void begin()

progress

public abstract void progress(long current,
                              java.lang.String info)

done

public void done()


Copyright © 2010. All Rights Reserved.