Examples of negate()


Examples of org.exist.xquery.value.NumericValue.negate()

        if (item.isEmpty())
          {return item;}
       
    NumericValue value = (NumericValue)item.convertTo(Type.NUMBER);
    if(mode == Constants.MINUS)
            {result = value.negate();}
    else
            {result =  value;}
       
        if (context.getProfiler().isEnabled())
            {context.getProfiler().end(this, "", result);}
View Full Code Here

Examples of org.geotools.referencing.operation.matrix.GeneralMatrix.negate()

            /**constrains**/
            GeneralMatrix AB = createAB(ATA, getB());

            AB.invert();
            AB.negate();

            GeneralMatrix AU = createAU(ATl, getU());
            xk.mul(AB, AU);

            xk.copySubMatrix(0, 0, 6, xk.getNumCol(), 0, 0, dxMatrix);
View Full Code Here

Examples of org.h2.value.ValueTime.negate()

        assertEquals("11:11:11", t1.getTime().toString());
        assertEquals("1970-01-01", t1.getDate().toString());
        assertEquals("TIME '11:11:11'", t1.getSQL());
        assertEquals("TIME '11:11:11'", t1.toString());
        assertEquals(1, t1.getSignum());
        assertEquals(-1, t1.negate().getSignum());
        assertEquals(0, t1.multiply(ValueInt.get(0)).getSignum());
        assertEquals(0, t1.subtract(t1).getSignum());
        assertEquals("05:35:35.5", t1.multiply(ValueDouble.get(0.5)).getString());
        assertEquals("22:22:22", t1.divide(ValueDouble.get(0.5)).getString());
        assertEquals("-11:11:11", t1.negate().getString());
View Full Code Here

Examples of org.h2.value.ValueTime.negate()

        assertEquals(-1, t1.negate().getSignum());
        assertEquals(0, t1.multiply(ValueInt.get(0)).getSignum());
        assertEquals(0, t1.subtract(t1).getSignum());
        assertEquals("05:35:35.5", t1.multiply(ValueDouble.get(0.5)).getString());
        assertEquals("22:22:22", t1.divide(ValueDouble.get(0.5)).getString());
        assertEquals("-11:11:11", t1.negate().getString());
        assertEquals("11:11:11", t1.negate().negate().getString());
        assertEquals(Value.TIME, t1.getType());
        long nanos = t1.getNanos();
        assertEquals((int) ((nanos >>> 32) ^ nanos), t1.hashCode());
        assertEquals(t1.getString().length(), t1.getDisplaySize());
View Full Code Here

Examples of org.h2.value.ValueTime.negate()

        assertEquals(0, t1.multiply(ValueInt.get(0)).getSignum());
        assertEquals(0, t1.subtract(t1).getSignum());
        assertEquals("05:35:35.5", t1.multiply(ValueDouble.get(0.5)).getString());
        assertEquals("22:22:22", t1.divide(ValueDouble.get(0.5)).getString());
        assertEquals("-11:11:11", t1.negate().getString());
        assertEquals("11:11:11", t1.negate().negate().getString());
        assertEquals(Value.TIME, t1.getType());
        long nanos = t1.getNanos();
        assertEquals((int) ((nanos >>> 32) ^ nanos), t1.hashCode());
        assertEquals(t1.getString().length(), t1.getDisplaySize());
        assertEquals(ValueTime.PRECISION, t1.getPrecision());
View Full Code Here

Examples of org.hsqldb.types.IntervalType.negate()

                Object       interval = scanner.newInterval(s, dataType);

                dataType = (IntervalType) scanner.dateTimeType;

                if (minus) {
                    interval = dataType.negate(interval);
                }

                return new ExpressionValue(interval, dataType);
            }
            default :
View Full Code Here

Examples of org.hsqldb.types.Type.negate()

                Object       interval = scanner.newInterval(s, dataType);

                dataType = (IntervalType) scanner.dateTimeType;

                if (minus) {
                    interval = dataType.negate(interval);
                }

                return new ExpressionValue(interval, dataType);
            }
            default :
View Full Code Here

Examples of org.hsqldb_voltpatches.types.IntervalType.negate()

                Object       interval = scanner.newInterval(s, dataType);

                dataType = (IntervalType) scanner.dateTimeType;

                if (minus) {
                    interval = dataType.negate(interval);
                }

                return new ExpressionValue(interval, dataType);
            }
            default :
View Full Code Here

Examples of org.hsqldb_voltpatches.types.Type.negate()

                Object       interval = scanner.newInterval(s, dataType);

                dataType = (IntervalType) scanner.dateTimeType;

                if (minus) {
                    interval = dataType.negate(interval);
                }

                return new ExpressionValue(interval, dataType);
            }
            default :
View Full Code Here

Examples of org.jamesii.core.math.complex.ComplexArray1D.negate()

   */
  public void testNegateExceptions() {
    ComplexArray1D a = new ComplexArray1D(new Complex[] { new Complex(1, 1) });

    try {
      a.negate(-1);
      fail();
    } catch (IndexOutOfBoundsException e) {
      assertTrue(true);
    } catch (Exception e) {
      fail();
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.