JML

org.multijava.mjc
Class SafeIntegralArithmetic

java.lang.Object
  extended byorg.multijava.mjc.SafeIntegralArithmetic

public class SafeIntegralArithmetic
extends Object


Constructor Summary
SafeIntegralArithmetic()
           
 
Method Summary
static int add(int arg1, int arg2)
           
static long add(long arg1, long arg2)
           
static double checked(double i)
           
static float checked(float i)
           
static int checked(int i)
           
static long checked(long i)
           
static int divide(int arg1, int arg2)
           
static long divide(long arg1, long arg2)
           
static int multiply(int arg1, int arg2)
           
static long multiply(long arg1, long arg2)
           
static int negate(int arg)
           
static long negate(long arg)
           
private static ArithmeticException newArithException(String expr)
           
private static ArithmeticException newArithException(String operatorAndSignature, long arg1, long arg2)
           
static int subtract(int arg1, int arg2)
           
static long subtract(long arg1, long arg2)
           
static double unchecked(double i)
           
static float unchecked(float i)
           
static int unchecked(int i)
           
static long unchecked(long i)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SafeIntegralArithmetic

public SafeIntegralArithmetic()
Method Detail

newArithException

private static ArithmeticException newArithException(String expr)

newArithException

private static ArithmeticException newArithException(String operatorAndSignature,
                                                     long arg1,
                                                     long arg2)

add

public static final int add(int arg1,
                            int arg2)

add

public static final long add(long arg1,
                             long arg2)

subtract

public static final int subtract(int arg1,
                                 int arg2)

subtract

public static final long subtract(long arg1,
                                  long arg2)

negate

public static final int negate(int arg)

negate

public static final long negate(long arg)

multiply

public static final int multiply(int arg1,
                                 int arg2)

multiply

public static final long multiply(long arg1,
                                  long arg2)

divide

public static final int divide(int arg1,
                               int arg2)

divide

public static final long divide(long arg1,
                                long arg2)

checked

public static final int checked(int i)

unchecked

public static final int unchecked(int i)

checked

public static final long checked(long i)

unchecked

public static final long unchecked(long i)

checked

public static final float checked(float i)

unchecked

public static final float unchecked(float i)

checked

public static final double checked(double i)

unchecked

public static final double unchecked(double i)

JML

JML is Copyright (C) 1998-2002 by Iowa State University and is distributed under the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This release depends on code from the MultiJava project and is based in part on the Kopi project Copyright (C) 1990-99 DMS Decision Management Systems Ges.m.b.H.