net.sf.plausj.bank.german.util
Class MathHelper

java.lang.Object
  extended by net.sf.plausj.bank.german.util.MathHelper

public class MathHelper
extends java.lang.Object

Some mathematical helper functions. They are called statically

Author:
ninan

Method Summary
static int calcCrossTotal(int aNumber)
          Calculates the cross total of the supplied integer
static int getLastDigits(int aNumber, int count)
          Returns the last "count" digits of the supplied number as a new integer
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

calcCrossTotal

public static int calcCrossTotal(int aNumber)
Calculates the cross total of the supplied integer

Parameters:
aNumber - The integer to calc the cross total from
Returns:
The cross total of the supplied integer

getLastDigits

public static int getLastDigits(int aNumber,
                                int count)
Returns the last "count" digits of the supplied number as a new integer

Parameters:
aNumber - The number to return the digits from
count - The count (from the right) of how many digits to return
Returns:
"count" digits of "aNumber"


Copyright © 2005-2007 null. All Rights Reserved.