|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.opensha.commons.eq.cat.filters.CatalogBrush
public class CatalogBrush
This class may be used to efficiently brush catalog data. Specifically, the
following DataTypes can be filtered using min-max constraints:
[ TIME, LATITUDE,LONGITUDE, DEPTH, MAGNITUDE ] For large
catalogs it has a significant memory footprint once instantiated because it
internally manages index arrays and sorted copies of catalog source data
arrays.
| Nested Class Summary | |
|---|---|
static class |
CatalogBrush.LimitKey
Key used to identify whether DataBrush should adjust a minimum or a maximum value. |
static class |
CatalogBrush.SelectionChange
Identifies a type of selection change. |
| Constructor Summary | |
|---|---|
CatalogBrush(MutableCatalog catalog)
Initializes a new data brush with the supplied catalog. |
|
| Method Summary | |
|---|---|
CatalogBrush.SelectionChange |
adjust(CatalogBrush.LimitKey key,
long value)
|
CatalogBrush.SelectionChange |
adjust(DataType type,
CatalogBrush.LimitKey key,
double newValue)
Adjusts the catalog selection and returns a flag describing the change. |
BitSet |
selection()
Returns the current selection as a BitSet. |
BitSet |
selectionChange()
Returns the current selection change as a BitSet. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CatalogBrush(MutableCatalog catalog)
catalog - | Method Detail |
|---|
public BitSet selection()
BitSet.
public BitSet selectionChange()
BitSet.
public CatalogBrush.SelectionChange adjust(CatalogBrush.LimitKey key,
long value)
public CatalogBrush.SelectionChange adjust(DataType type,
CatalogBrush.LimitKey key,
double newValue)
DataType supplied is not applicable for the
associated catalog, the supplied value is out of range for the the
DataType, or the selection hasn't changed,
SelectionChange.NONE is returned. Otherwise method returns
SelectionChange.ADD or SelectionChange.REMOVE.
Once method returns, the BitSet returned by
selectionChange() represents the change.
type - of data to adjustkey - to adjust - min or max limitnewValue - for limit
true if catalog selection has changed,
false otherwise
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||