|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object visad.data.dods.Valuator
public abstract class Valuator
Provides support for processing numeric values in a DODS dataset. Processing includes checking for non-equality with "missing" or "fill" values, unpacking into more capacious data types, and checking that the values lie within a valid range.
Instances are immutable.
Field Summary | |
---|---|
protected ValueRanger |
ranger
|
protected ValueUnpacker |
unpacker
|
protected ValueVetter |
vetter
|
Constructor Summary | |
---|---|
protected |
Valuator(dods.dap.AttributeTable table)
Constructs from the attributes of a DODS variable. |
Method Summary | |
---|---|
protected static double |
decode(String name,
dods.dap.AttributeTable table,
int index)
Decodes an attribute for a DODS variable. |
abstract SimpleSet |
getRepresentationalSet(RealType realType)
Returns the set used to represent unpacked, numeric values associated with this instance in the range of a VisAD FlatField . |
double |
process(double value)
Processes values. |
double[] |
process(double[] values)
Processes values. |
float |
process(float value)
Processes a value. |
float[] |
process(float[] values)
Processes a value. |
static Valuator |
valuator(dods.dap.AttributeTable table,
int type)
Returns an instance of this class corresponding to the attributes for a DODS variable. |
static ValueRanger |
valueRanger(dods.dap.AttributeTable table)
Returns an instance of a value ranger corresponding to the attributes of a DODS variable. |
static ValueUnpacker |
valueUnpacker(dods.dap.AttributeTable table)
Returns an instance of a value unpacker corresponding to the attributes of a DODS variable. |
static ValueVetter |
valueVetter(dods.dap.AttributeTable table)
Returns an instance of a value vetter corresponding to the attributes of a DODS variable. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final ValueVetter vetter
protected final ValueUnpacker unpacker
protected final ValueRanger ranger
Constructor Detail |
---|
protected Valuator(dods.dap.AttributeTable table) throws BadFormException, VisADException, RemoteException
table
- The attribute table for a DODS variable.
BadFormException
- The attribute table is corrupt.
VisADException
- VisAD failure.
RemoteException
- Java RMI failure.Method Detail |
---|
public static Valuator valuator(dods.dap.AttributeTable table, int type) throws BadFormException, VisADException, RemoteException
table
- The attribute table for a DODS variable.type
- The type of packed variable: Attribute.BYTE
, Attribute.INT16
, etc.
BadFormException
- The attribute table is corrupt.
VisADException
- VisAD failure.
RemoteException
- Java RMI failure.public abstract SimpleSet getRepresentationalSet(RealType realType) throws VisADException
FlatField
.
VisADException
- VisAD failure.public float process(float value)
value
- The value to be processed.public float[] process(float[] values)
values
- The values to be processed.public double process(double value)
value
- The value to be processed.public double[] process(double[] values)
values
- The values to be processed.protected static double decode(String name, dods.dap.AttributeTable table, int index) throws BadFormException, VisADException, RemoteException
name
- The name of the attribute.table
- The attribute table of the DODS variable.index
- The index of the attribute element to be
decoded.
BadFormException
- The DODS information is corrupt.
VisADException
- VisAD failure.
RemoteException
- Java RMI failure.public static ValueVetter valueVetter(dods.dap.AttributeTable table) throws BadFormException, VisADException, RemoteException
table
- The DODS attribute table. May be
null
, in which case a trivial
vetter is returned.
BadFormException
- The attribute table is corrupt.
VisADException
- VisAD failure.
RemoteException
- Java RMI failure.public static ValueUnpacker valueUnpacker(dods.dap.AttributeTable table) throws BadFormException, VisADException, RemoteException
table
- A DODS attribute table. May be
null
, in which case a trivial
unpacker is returned.
BadFormException
- The attribute table is corrupt.
VisADException
- VisAD failure.
RemoteException
- Java RMI exception.public static ValueRanger valueRanger(dods.dap.AttributeTable table) throws BadFormException, VisADException, RemoteException
table
- A DODS attribute table. May be
null
, in which case a trivial
ranger is returned.
BadFormException
- The attribute table is corrupt.
VisADException
- VisAD failure.
RemoteException
- Java RMI exception.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |