java.util
Class IllegalFormatConversionException

java.lang.Object
  extended byjava.lang.Throwable
      extended byjava.lang.Exception
          extended byjava.lang.RuntimeException
              extended byjava.lang.IllegalArgumentException
                  extended byjava.util.IllegalFormatException
                      extended byjava.util.IllegalFormatConversionException
All Implemented Interfaces:
Serializable

public class IllegalFormatConversionException
extends IllegalFormatException
implements Serializable

The unchecked exception will be thrown out when the parameter is incompatible with the corresponding format specifier.

Since:
1.5
See Also:
Serialized Form

Constructor Summary
IllegalFormatConversionException(char c, java.lang.Class arg)
          Constructs an IllegalFormatConversionException with the class of the mismatched conversion and corresponding parameter.
 
Method Summary
 java.lang.Class getArgumentClass()
          Return the class of the mismatched parameter.
 char getConversion()
          Return the incompatible conversion.
 java.lang.String getMessage()
          Return the message string of the IllegalFormatConversionException.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IllegalFormatConversionException

public IllegalFormatConversionException(char c,
                                        java.lang.Class arg)
Constructs an IllegalFormatConversionException with the class of the mismatched conversion and corresponding parameter.

Parameters:
c - The class of the mismatched conversion.
arg - The corresponding parameter.
Method Detail

getArgumentClass

public java.lang.Class getArgumentClass()
Return the class of the mismatched parameter.

Returns:
The class of the mismatched parameter.

getConversion

public char getConversion()
Return the incompatible conversion.

Returns:
The incompatible conversion.

getMessage

public java.lang.String getMessage()
Return the message string of the IllegalFormatConversionException.

Overrides:
getMessage in class Throwable
Returns:
The message string of the IllegalFormatConversionException.