org.apache.commons.math.fraction
Class FractionConversionException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by org.apache.commons.math.MathException
              extended by org.apache.commons.math.ConvergenceException
                  extended by org.apache.commons.math.fraction.FractionConversionException
All Implemented Interfaces:
java.io.Serializable

public class FractionConversionException
extends ConvergenceException

Error thrown when a double value cannot be converted to a fraction in the allowed number of iterations.

Since:
1.2
Version:
$Revision: 811685 $ $Date: 2009-09-05 13:36:48 -0400 (Sat, 05 Sep 2009) $
See Also:
Serialized Form

Field Summary
private static long serialVersionUID
          Serializable version identifier.
 
Constructor Summary
FractionConversionException(double value, int maxIterations)
          Constructs an exception with specified formatted detail message.
FractionConversionException(double value, long p, long q)
          Constructs an exception with specified formatted detail message.
 
Method Summary
 
Methods inherited from class org.apache.commons.math.MathException
getArguments, getLocalizedMessage, getMessage, getMessage, getPattern, printStackTrace, printStackTrace
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getStackTrace, initCause, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
Serializable version identifier.

See Also:
Constant Field Values
Constructor Detail

FractionConversionException

public FractionConversionException(double value,
                                   int maxIterations)
Constructs an exception with specified formatted detail message. Message formatting is delegated to MessageFormat.

Parameters:
value - double value to convert
maxIterations - maximal number of iterations allowed

FractionConversionException

public FractionConversionException(double value,
                                   long p,
                                   long q)
Constructs an exception with specified formatted detail message. Message formatting is delegated to MessageFormat.

Parameters:
value - double value to convert
p - current numerator
q - current denominator


Copyright (c) 2003-2010 Apache Software Foundation