|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectvisad.data.netcdf.QuantityDB
public abstract class QuantityDB
Provides support for a database of quantities.
| Field Summary | |
|---|---|
static QuantityDB |
emptyDB
The empty quantity database. |
| Constructor Summary | |
|---|---|
QuantityDB()
|
|
| Method Summary | |
|---|---|
void |
add(Quantity quantity)
Adds a given Quantity to the database. |
abstract void |
add(String name,
Quantity quantity)
Adds a given Quantity to the database under a given name. |
abstract Quantity |
get(String name)
Returns the quantity in the database whose name matches a given name. |
Quantity |
get(String name,
String unitSpec)
Returns the quantity that matches the given name and unit. |
abstract Quantity[] |
get(Unit unit)
Returns all quantities in the database whose default unit is convertible with a given unit. |
abstract Iterator |
nameIterator()
Returns an iterator of the names in the database. |
abstract Iterator |
quantityIterator()
Returns an iterator of the quantities in the database. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final QuantityDB emptyDB
| Constructor Detail |
|---|
public QuantityDB()
| Method Detail |
|---|
public abstract Quantity get(String name)
name - The name of the quantity.
name. Note that
RETURN_VALUE.getName().equals(name) can
be false due to aliasing.public abstract Quantity[] get(Unit unit)
unit - The unit of the quantity.
unit.
public Quantity get(String name,
String unitSpec)
throws ParseException,
NoSuchUnitException,
UnitException,
VisADException
name - The name of the quantity.unitSpec - The unit of the quantity.
name and unit. Note
that RETURN_VALUE.getName().equals(name)
can be false due to
aliasing and RETURN_VALUE.
getDefaultUnit().equals(unit) can be
false due to allowable unit
conversion.
ParseException - Couldn't decode unitSpec.
NoSuchUnitException - unitSpec not in unit database.
UnitException - The quantity already exists with an
incompatible unit.
VisADException - Couldn't create necessary VisAD object.
public abstract void add(String name,
Quantity quantity)
throws VisADException
name - The name under which the quantity is to be
added. May be an alias.quantity - The quantity to be added.
VisADException - Couldn't create necessary VisAD object.
public void add(Quantity quantity)
throws VisADException
quantity - The quantity to be added. The quantity will
be added under it own name.
VisADException - Couldn't create necessary VisAD object.public abstract Iterator quantityIterator()
public abstract Iterator nameIterator()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||