org.geotools.referencing.piecewise
Class DefaultLinearPiecewiseTransform1DElement

java.lang.Object
  extended by org.geotools.referencing.piecewise.DefaultDomainElement1D
      extended by org.geotools.referencing.piecewise.DefaultPiecewiseTransform1DElement
          extended by org.geotools.referencing.piecewise.DefaultLinearPiecewiseTransform1DElement
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<DomainElement1D>, DomainElement1D, PiecewiseTransform1DElement, org.opengis.referencing.operation.MathTransform, org.opengis.referencing.operation.MathTransform1D
Direct Known Subclasses:
LinearColorMapElement

public class DefaultLinearPiecewiseTransform1DElement
extends DefaultPiecewiseTransform1DElement
implements PiecewiseTransform1DElement

Convenience class for linear transformations that maps an interval to another interval.

Author:
Simone Giannecchini, GeoSolutions
See Also:
Serialized Form

Constructor Summary
DefaultLinearPiecewiseTransform1DElement(java.lang.CharSequence name, NumberRange<? extends java.lang.Number> inRange, NumberRange<? extends java.lang.Number> outRange)
          Constructor.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Implementation of Object.equals(Object) for DomainElement1Ds.
protected  java.lang.Class<?> getEquivalenceClass()
           
 double getOffset()
          Retrieves the offset factor for this linear PiecewiseTransform1DElement.
 double getOutputMaximum()
          Returns the maximum output values for this DefaultLinearPiecewiseTransform1DElement ;
 double getOutputMinimum()
          Returns the minimum output values for this DefaultLinearPiecewiseTransform1DElement ;
 NumberRange<? extends java.lang.Number> getOutputRange()
          Returns the range for the output values for this DefaultLinearPiecewiseTransform1DElement ;
 double getScale()
          Retrieves the scale factor for this linear PiecewiseTransform1DElement.
 int hashCode()
          Returns a hash value for this domain element.
 boolean isOutputMaximumInfinite()
          Tells me if the upper boundary of the output range is infinite
 boolean isOutputMaximumNaN()
          Tells me if the upper boundary of the output range is NaN
 boolean isOutputMinimumInfinite()
          Tells me if the lower boundary of the output range is infinite
 boolean isOutputMinimumNaN()
          Tells me if the lower boundary of the output range is NaN
 java.lang.String toString()
           
 
Methods inherited from class org.geotools.referencing.piecewise.DefaultPiecewiseTransform1DElement
create, create, create, create, create, create, create, derivative, derivative, getSourceDimensions, getTargetDimensions, getTransform, inverse, isIdentity, setInverse, setTransform, toWKT, transform, transform, transform, transform, transform, transform
 
Methods inherited from class org.geotools.referencing.piecewise.DefaultDomainElement1D
compareTo, contains, contains, contains, getInputMaximum, getInputMinimum, getName, getRange, isInputMaximumInfinite, isInputMaximumNaN, isInputMinimumInfinite, isInputMinimumNaN
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.geotools.referencing.piecewise.DomainElement1D
contains, contains, contains, getName, getRange
 
Methods inherited from interface java.lang.Comparable
compareTo
 
Methods inherited from interface org.opengis.referencing.operation.MathTransform1D
derivative, inverse, transform
 
Methods inherited from interface org.opengis.referencing.operation.MathTransform
derivative, getSourceDimensions, getTargetDimensions, isIdentity, toWKT, transform, transform, transform, transform, transform
 

Constructor Detail

DefaultLinearPiecewiseTransform1DElement

public DefaultLinearPiecewiseTransform1DElement(java.lang.CharSequence name,
                                                NumberRange<? extends java.lang.Number> inRange,
                                                NumberRange<? extends java.lang.Number> outRange)
Constructor.

Parameters:
name - for this DefaultLinearPiecewiseTransform1DElement.
inRange - for this DefaultLinearPiecewiseTransform1DElement.
outRange - for this DefaultLinearPiecewiseTransform1DElement.
Method Detail

getOutputMaximum

public double getOutputMaximum()
Returns the maximum output values for this DefaultLinearPiecewiseTransform1DElement ;

Returns:
the maximum output values for this DefaultLinearPiecewiseTransform1DElement ;

getOutputMinimum

public double getOutputMinimum()
Returns the minimum output values for this DefaultLinearPiecewiseTransform1DElement ;

Returns:
the minimum output values for this DefaultLinearPiecewiseTransform1DElement ;

getOutputRange

public NumberRange<? extends java.lang.Number> getOutputRange()
Returns the range for the output values for this DefaultLinearPiecewiseTransform1DElement ;

Returns:
the range for the output values for this DefaultLinearPiecewiseTransform1DElement ;

isOutputMinimumNaN

public boolean isOutputMinimumNaN()
Tells me if the lower boundary of the output range is NaN

Returns:
true if the lower boundary of the output range is NaN, false otherwise.

isOutputMaximumNaN

public boolean isOutputMaximumNaN()
Tells me if the upper boundary of the output range is NaN

Returns:
true if the upper boundary of the output range is NaN, false otherwise.

isOutputMinimumInfinite

public boolean isOutputMinimumInfinite()
Tells me if the lower boundary of the output range is infinite

Returns:
true if the lower boundary of the output range is infinite, false otherwise.

isOutputMaximumInfinite

public boolean isOutputMaximumInfinite()
Tells me if the upper boundary of the output range is infinite

Returns:
true if the upper boundary of the output range is infinite, false otherwise.

getScale

public double getScale()
Retrieves the scale factor for this linear PiecewiseTransform1DElement.

Returns:
the scale factor for this linear PiecewiseTransform1DElement.

getOffset

public double getOffset()
Retrieves the offset factor for this linear PiecewiseTransform1DElement.

Returns:
the offset factor for this linear PiecewiseTransform1DElement.

toString

public java.lang.String toString()
Overrides:
toString in class DefaultPiecewiseTransform1DElement

getEquivalenceClass

protected java.lang.Class<?> getEquivalenceClass()
Overrides:
getEquivalenceClass in class DefaultPiecewiseTransform1DElement

equals

public boolean equals(java.lang.Object obj)
Description copied from class: DefaultDomainElement1D
Implementation of Object.equals(Object) for DomainElement1Ds.

Two DefaultDomainElement1Ds are considered to be equal if they have the same inputr range and the same name.

Specified by:
equals in interface DomainElement1D
Overrides:
equals in class DefaultPiecewiseTransform1DElement
Parameters:
obj - the reference object with which to compare.
Returns:
true if this object is the same as the obj argument; false otherwise.
See Also:
Object.equals(Object)

hashCode

public int hashCode()
Description copied from class: DefaultDomainElement1D
Returns a hash value for this domain element. This value need not remain consistent between different implementations of the same class.

Overrides:
hashCode in class DefaultPiecewiseTransform1DElement


Copyright © 1996-2010 Geotools. All Rights Reserved.