1 21 22 package org.apache.derby.iapi.types; 23 24 import org.apache.derby.iapi.error.StandardException; 25 26 public interface NumberDataValue extends DataValueDescriptor 27 { 28 31 public static final int MIN_DECIMAL_DIVIDE_SCALE = 4; 32 public static final int MAX_DECIMAL_PRECISION_SCALE = 31; 33 34 46 public NumberDataValue plus(NumberDataValue addend1, 47 NumberDataValue addend2, 48 NumberDataValue result) 49 throws StandardException; 50 51 63 public NumberDataValue minus(NumberDataValue left, 64 NumberDataValue right, 65 NumberDataValue result) 66 throws StandardException; 67 68 80 public NumberDataValue times(NumberDataValue left, 81 NumberDataValue right, 82 NumberDataValue result) 83 throws StandardException; 84 85 97 public NumberDataValue divide(NumberDataValue dividend, 98 NumberDataValue divisor, 99 NumberDataValue result) 100 throws StandardException; 101 102 116 public NumberDataValue divide(NumberDataValue dividend, 117 NumberDataValue divisor, 118 NumberDataValue result, 119 int scale) 120 throws StandardException; 121 122 123 135 public NumberDataValue mod(NumberDataValue dividend, 136 NumberDataValue divisor, 137 NumberDataValue result) 138 throws StandardException; 139 140 150 public NumberDataValue minus(NumberDataValue result) 151 throws StandardException; 152 153 161 public NumberDataValue absolute(NumberDataValue result) 162 throws StandardException; 163 164 172 public NumberDataValue sqrt(NumberDataValue result) 173 throws StandardException; 174 175 195 public void setValue(Number theValue) throws StandardException; 196 197 204 public int getDecimalValuePrecision(); 205 206 213 public int getDecimalValueScale(); 214 } 215 216 217 218 219 220 221 222 223 224 | Popular Tags |