Class Parameter<T>

Type Parameters:
T - The value type.
All Implemented Interfaces:
Serializable, Cloneable, GeneralParameterValue, ParameterValue<T>, Cloneable

public class Parameter<T> extends AbstractParameter implements ParameterValue<T>
A parameter value used by an operation method. Most CRS parameter values are numeric, but other types of parameter values are possible. The parameter type can be fetch with the getValue().getClass() idiom. The getValue() and setValue(Object) methods can be invoked at any time. Others getters and setters are parameter-type dependents.
Since:
2.1
Author:
Martin Desruisseaux (IRD), Jody Garnett (Refractions Research)
See Also:
  • Field Summary

    Fields inherited from class Formattable

    SINGLE_LINE
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructs a parameter value from the specified descriptor.
    Parameter(ParameterDescriptor<T> descriptor, T value)
    Constructs a parameter value from the specified descriptor and value.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns the boolean value of an operation parameter.
    Returns a clone of this parameter.
    create(String name, double value, Unit<?> unit)
    Constructs a parameter from the specified name and value.
    create(String name, int value)
    Constructs a parameter from the specified name and value.
    static <T extends CodeList>
    Parameter<T>
    create(String name, Class<T> type, T value)
    Constructs a parameter from the specified code list.
    double
    Returns the numeric value of the coordinate operation parameter with its associated unit of measure.
    double
    doubleValue(Unit<?> unit)
    Returns the numeric value of the coordinate operation parameter in the specified unit of measure.
    double[]
    Returns an ordered sequence of two or more numeric values of an operation parameter list, where each value has the same associated unit of measure.
    double[]
    doubleValueList(Unit<?> unit)
    Returns an ordered sequence of numeric values in the specified unit of measure.
    static <T> T
    Ensures that the given value is valid according the specified parameter descriptor.
    boolean
    equals(Object object)
    Compares the specified object with this parameter for equality.
    Returns the abstract definition of this parameter.
    Unit<?>
    Returns the unit of measure of the parameter value.
    Returns the parameter value as an object.
    int
    Returns a hash value for this parameter.
    int
    Returns the positive integer value of an operation parameter, usually used for a count.
    int[]
    Returns an ordered sequence of two or more integer values of an operation parameter list, usually used for counts.
    void
    setValue(boolean value)
    Sets the parameter value as a boolean.
    void
    setValue(double value)
    Sets the parameter value as a floating point.
    void
    setValue(double[] values, Unit<?> unit)
    Set the parameter value as an array of floating point and their associated unit.
    void
    setValue(double value, Unit<?> unit)
    Sets the parameter value as a floating point and its associated unit.
    void
    setValue(int value)
    Sets the parameter value as an integer.
    void
    Set the parameter value as an object.
    Returns the string value of an operation parameter.
    Returns a reference to a file or a part of a file containing one or more parameter values.

    Methods inherited from class AbstractParameter

    formatWKT, toString, write

    Methods inherited from class Formattable

    cleanupThreadLocals, toWKT, toWKT, toWKT, toWKT

    Methods inherited from class Object

    finalize, getClass, notify, notifyAll, wait, wait, wait