Chapter 7. ThresholdList

Table of Contents

ThresholdList
The ThresholdEvaluator Interface
The ThresholdList BoundedRangeModel
Other Models
So What?

In part seven we are adding a third kind of filtering to the issue list. This filter will allow a user to display the full range of issue priorities or focus in on only the most important issues. The list filtering will be driven by a slider widget.

ThresholdList

The ThresholdList performs specialized filter functionality. It provides a view of a source list that is described by a bounded-range. The range is bounded by two integer values which represent the upper and lower thresholds as to what values belong to this list. To allow a high level of customization and control, the ThresholdList uses the ThresholdEvaluator interface to evaluate the elements of the list. This is parallel in spirit to the Comparator interface, but evaluates an Object giving an absolute integer value as a result rather than a relative one. The ThresholdList makes use of a ThresholdEvaluator to determine which Objects fall within the bounded-range.