Package org.opengis.filter.expression

Examples of org.opengis.filter.expression.Function.evaluate()


                assertTrue("ceil of (1.5707963267948966):", Double
                        .isNaN(((Double) ceilFunction.evaluate(null))
                                .doubleValue()));
            } else {
                assertEquals("ceil of (1.5707963267948966):", (double) Math
                        .ceil(1.5707963267948966), ((Double) ceilFunction
                        .evaluate(null)).doubleValue(), 0.00001);
            }
        } catch (FactoryRegistryException e) {
            e.printStackTrace();
            fail("Unexpected exception: " + e.getMessage());
View Full Code Here


            assertEquals("Number of arguments, ", 1, exp.getFunctionName().getArgumentCount());

            Function expFunction = ff.function("exp", literal_1);
            double good0 = Math.exp(1.0);
            if (Double.isNaN(good0)) {
                assertTrue("exp of (1.0):", Double.isNaN(((Double) expFunction
                        .evaluate(null)).doubleValue()));
            } else {
                assertEquals("exp of (1.0):", (double) Math.exp(1.0),
                        ((Double) expFunction.evaluate(null)).doubleValue(),
                        0.00001);
View Full Code Here

            if (Double.isNaN(good0)) {
                assertTrue("exp of (1.0):", Double.isNaN(((Double) expFunction
                        .evaluate(null)).doubleValue()));
            } else {
                assertEquals("exp of (1.0):", (double) Math.exp(1.0),
                        ((Double) expFunction.evaluate(null)).doubleValue(),
                        0.00001);
            }
           
            expFunction = ff.function("exp", literal_m1);
            double good1 = Math.exp(-1.0);
View Full Code Here

            }
           
            expFunction = ff.function("exp", literal_m1);
            double good1 = Math.exp(-1.0);
            if (Double.isNaN(good1)) {
                assertTrue("exp of (-1.0):", Double.isNaN(((Double) expFunction
                        .evaluate(null)).doubleValue()));
            } else {
                assertEquals("exp of (-1.0):", (double) Math.exp(-1.0),
                        ((Double) expFunction.evaluate(null)).doubleValue(),
                        0.00001);
View Full Code Here

            if (Double.isNaN(good1)) {
                assertTrue("exp of (-1.0):", Double.isNaN(((Double) expFunction
                        .evaluate(null)).doubleValue()));
            } else {
                assertEquals("exp of (-1.0):", (double) Math.exp(-1.0),
                        ((Double) expFunction.evaluate(null)).doubleValue(),
                        0.00001);
            }
           
            expFunction = ff.function("exp", literal_2);
            double good2 = Math.exp(2.0);
View Full Code Here

            }
           
            expFunction = ff.function("exp", literal_2);
            double good2 = Math.exp(2.0);
            if (Double.isNaN(good2)) {
                assertTrue("exp of (2.0):", Double.isNaN(((Double) expFunction
                        .evaluate(null)).doubleValue()));
            } else {
                assertEquals("exp of (2.0):", (double) Math.exp(2.0),
                        ((Double) expFunction.evaluate(null)).doubleValue(),
                        0.00001);
View Full Code Here

            if (Double.isNaN(good2)) {
                assertTrue("exp of (2.0):", Double.isNaN(((Double) expFunction
                        .evaluate(null)).doubleValue()));
            } else {
                assertEquals("exp of (2.0):", (double) Math.exp(2.0),
                        ((Double) expFunction.evaluate(null)).doubleValue(),
                        0.00001);
            }
           
            expFunction = ff.function("exp", literal_m2);
            double good3 = Math.exp(-2.0);
View Full Code Here

            }
           
            expFunction = ff.function("exp", literal_m2);
            double good3 = Math.exp(-2.0);
            if (Double.isNaN(good3)) {
                assertTrue("exp of (-2.0):", Double.isNaN(((Double) expFunction
                        .evaluate(null)).doubleValue()));
            } else {
                assertEquals("exp of (-2.0):", (double) Math.exp(-2.0),
                        ((Double) expFunction.evaluate(null)).doubleValue(),
                        0.00001);
View Full Code Here

            if (Double.isNaN(good3)) {
                assertTrue("exp of (-2.0):", Double.isNaN(((Double) expFunction
                        .evaluate(null)).doubleValue()));
            } else {
                assertEquals("exp of (-2.0):", (double) Math.exp(-2.0),
                        ((Double) expFunction.evaluate(null)).doubleValue(),
                        0.00001);
            }
           
            expFunction = ff.function("exp", literal_pi);
            double good4 = Math.exp(Math.PI);
View Full Code Here

           
            expFunction = ff.function("exp", literal_pi);
            double good4 = Math.exp(Math.PI);
            if (Double.isNaN(good4)) {
                assertTrue("exp of (3.141592653589793):", Double
                        .isNaN(((Double) expFunction.evaluate(null))
                                .doubleValue()));
            } else {
                assertEquals("exp of (3.141592653589793):", (double) Math
                        .exp(3.141592653589793), ((Double) expFunction
                        .evaluate(null)).doubleValue(), 0.00001);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.