|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Meter
meters show progress.
Currently the issue of multiple copies of the same listener is ill-defined. The intent is to move to a set-based model but the current default implementation is list-based. That means currently if a listener is added more than once it will be called that many times. That will be changed as soon as feasible.
Nested Class Summary | |
---|---|
static class |
Meter.State
Enumeration of possible states |
Method Summary | |
---|---|
void |
addEventListener(MeterEventListener l)
add the given listener to the meter |
void |
cancel()
request that the underlying process cancel |
java.lang.String |
getCaption()
returns the caption of the meter. |
boolean |
getHasGauge()
returns whether the meter has a gauge. |
boolean |
getHasLabel()
returns whether the meter has a label showing |
java.lang.String |
getLabel()
returns the label, if there is one |
double |
getLevel()
gets the current level of the gauge |
double |
getMaximumLevel()
gets the maximum level of the gauge |
double |
getMinimumLevel()
gets the minimum level of the gauge |
Meter.State |
getState()
gets the current state of the meter |
boolean |
isCancelable()
gets whether the meter can be cancelled |
void |
removeEventListener(MeterEventListener l)
removes a listener previously added by addEventListener(MeterEventListener) . |
Method Detail |
---|
void addEventListener(MeterEventListener l)
l
- the MeterEventListener
listenerremoveEventListener(MeterEventListener)
void cancel()
java.lang.IllegalStateException
- if the meter can not be cancelledisCancelable()
java.lang.String getCaption()
The caption does not change.
boolean getHasGauge()
Even if this returns false the gauge-related methods will still return a value
true
if the meter has a gaugeboolean getHasLabel()
true
if the meter has a labelgetLabel()
java.lang.String getLabel()
double getLevel()
double getMaximumLevel()
The maximum level may change during the life of the meter
double getMinimumLevel()
The minimum level may change during the life of the meter
Meter.State getState()
Meter.State
representing the current state of the meterboolean isCancelable()
true
if the meter can be cancelledcancel()
void removeEventListener(MeterEventListener l)
addEventListener(MeterEventListener)
.
l
- the MeterEventListener
listener that was added and is to
be removed
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |