"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "modules/library/main/src/main/java/org/geotools/filter/function/math/FilterFunction_IEEEremainder.java" between
geotools-21.1-project.zip and geotools-21.2-project.zip

About: GeoTools (The Open Source Java GIS Toolkit) is a Java code library which provides standards compliant methods for the manipulation of geospatial data.

FilterFunction_IEEEremainder.java  (geotools-21.1-project):FilterFunction_IEEEremainder.java  (geotools-21.2-project)
skipping to change at line 26 skipping to change at line 26
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details. * Lesser General Public License for more details.
*/ */
// this code is autogenerated - you shouldnt be modifying it! // this code is autogenerated - you shouldnt be modifying it!
import static org.geotools.filter.capability.FunctionNameImpl.*; import static org.geotools.filter.capability.FunctionNameImpl.*;
import org.geotools.filter.FunctionExpressionImpl; import org.geotools.filter.FunctionExpressionImpl;
import org.geotools.filter.capability.FunctionNameImpl; import org.geotools.filter.capability.FunctionNameImpl;
import org.geotools.util.Converters;
import org.geotools.util.factory.Hints;
import org.opengis.filter.capability.FunctionName; import org.opengis.filter.capability.FunctionName;
public class FilterFunction_IEEEremainder extends FunctionExpressionImpl { public class FilterFunction_IEEEremainder extends FunctionExpressionImpl {
// public static FunctionName NAME = new FunctionNameImpl("IEEEremainder","d ividend","divisor"); // public static FunctionName NAME = new FunctionNameImpl("IEEEremainder","d ividend","divisor");
public static FunctionName NAME = public static FunctionName NAME =
new FunctionNameImpl( new FunctionNameImpl(
"IEEEremainder", "IEEEremainder",
parameter("remainder", Double.class), parameter("remainder", Double.class),
parameter("dividend", Number.class), parameter("dividend", Number.class),
parameter("divisor", Number.class)); parameter("divisor", Number.class));
public FilterFunction_IEEEremainder() { public FilterFunction_IEEEremainder() {
super("IEEEremainder"); super("IEEEremainder");
functionName = NAME; functionName = NAME;
} }
public Object evaluate(Object feature) { public Object evaluate(Object feature) {
double arg0;
double arg1;
try { // attempt to get value and perform conversion Object arg0 = getExpression(0).evaluate(feature);
arg0 = getExpression(0).evaluate(feature, Double.class).doubleValue( Object arg1 = getExpression(1).evaluate(feature);
); if (arg0 == null || arg1 == null) {
} catch (Exception e) { return null;
}
arg0 =
Converters.convert(
arg0,
Double.class,
new Hints()); // attempt to get value and perform conver
sion
arg1 = Converters.convert(arg1, Double.class, new Hints());
if (arg0 == null) {
// probably a type error // probably a type error
throw new IllegalArgumentException( throw new IllegalArgumentException(
"Filter Function problem for function IEEEremainder argument #0 - expected type double"); "Filter Function problem for function IEEEremainder argument #0 - expected type double");
} }
if (arg1 == null) {
try { // attempt to get value and perform conversion
arg1 = getExpression(1).evaluate(feature, Double.class).doubleValue(
);
} catch (Exception e) {
// probably a type error // probably a type error
throw new IllegalArgumentException( throw new IllegalArgumentException(
"Filter Function problem for function IEEEremainder argument #1 - expected type double"); "Filter Function problem for function IEEEremainder argument #1 - expected type double");
} }
return new Double(Math.IEEEremainder(arg0, arg1)); return (Math.IEEEremainder((Double) arg0, (Double) arg1));
} }
} }
 End of changes. 5 change blocks. 
12 lines changed or deleted 19 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)