|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.geotools.filter.InterpolateFunction
public class InterpolateFunction
This is an implemenation of the Interpolate function as defined by OGC Symbology Encoding (SE) 1.1 specification.
The first parameter should be either the name of a numeric feature property or, if this function is being used as a raster colormap, the String "RasterData" (case-insensitive).
Following this there should be a sequence of interpolation points, each of which is described by two parameters: the first a datum and the second a return value. In the SE speicification these parameters are expected to be Literals but in this implementation more general Expressions are also supported.
Two optional parameters can be provided following the interpolation points: A "method" parameter which can take the values "numeric" or "color" and a "mode" parameter which can take the values "linear", "cosine" or "cubic" (Note: it would make more sense if these terms were reversed but we are adhering to their use as published in the OGC specification).
Number of points and interpolation modes
Exception
is thrown.
Nested Class Summary | |
---|---|
static class |
InterpolateFunction.Name
Describe how this function works. |
Field Summary | |
---|---|
static java.lang.String |
METHOD_COLOR
Use as a literal value to indicate interpolation method |
static java.lang.String |
METHOD_NUMERIC
Use as a literal value to indicate interpolation method |
static java.lang.String |
MODE_COSINE
Use as a literal value to indicate interpolation mode |
static java.lang.String |
MODE_CUBIC
Use as a literal value to indicate interpolation mode |
static java.lang.String |
MODE_LINEAR
Use as a literal value to indicate interpolation mode |
static org.opengis.filter.capability.FunctionName |
NAME
Make the instance of FunctionName available in a consistent spot. |
static java.lang.String |
RASTER_DATA
Use as a PropertyName when defining a color map. |
Fields inherited from interface org.opengis.filter.expression.Expression |
---|
NIL |
Constructor Summary | |
---|---|
InterpolateFunction()
|
|
InterpolateFunction(java.util.List<org.opengis.filter.expression.Expression> parameters,
org.opengis.filter.expression.Literal fallback)
|
Method Summary | ||
---|---|---|
java.lang.Object |
accept(org.opengis.filter.expression.ExpressionVisitor visitor,
java.lang.Object extraData)
|
|
java.lang.Object |
evaluate(java.lang.Object object)
|
|
|
evaluate(java.lang.Object object,
java.lang.Class<T> context)
|
|
org.opengis.filter.expression.Literal |
getFallbackValue()
|
|
java.lang.String |
getName()
|
|
java.util.List<org.opengis.filter.expression.Expression> |
getParameters()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String MODE_LINEAR
public static final java.lang.String MODE_COSINE
public static final java.lang.String MODE_CUBIC
public static final java.lang.String METHOD_NUMERIC
public static final java.lang.String METHOD_COLOR
public static final java.lang.String RASTER_DATA
public static final org.opengis.filter.capability.FunctionName NAME
Constructor Detail |
---|
public InterpolateFunction()
public InterpolateFunction(java.util.List<org.opengis.filter.expression.Expression> parameters, org.opengis.filter.expression.Literal fallback)
Method Detail |
---|
public java.lang.String getName()
getName
in interface org.opengis.filter.expression.Function
public java.util.List<org.opengis.filter.expression.Expression> getParameters()
getParameters
in interface org.opengis.filter.expression.Function
public java.lang.Object accept(org.opengis.filter.expression.ExpressionVisitor visitor, java.lang.Object extraData)
accept
in interface org.opengis.filter.expression.Expression
public java.lang.Object evaluate(java.lang.Object object)
evaluate
in interface org.opengis.filter.expression.Expression
public <T> T evaluate(java.lang.Object object, java.lang.Class<T> context)
evaluate
in interface org.opengis.filter.expression.Expression
public org.opengis.filter.expression.Literal getFallbackValue()
getFallbackValue
in interface org.opengis.filter.expression.Function
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |