Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.opengis.parameter
Class InvalidParameterTypeException

    Object
      Throwable
          Exception
              RuntimeException
                  IllegalStateException
                      InvalidParameterTypeException

All Implemented Interfaces:
  Serializable

    public class InvalidParameterTypeException

extends IllegalStateException

Thrown when a parameter can't be cast to the requested type. For example this exception is thrown when `ParameterValue.doubleValue(javax.units.Unit)` is invoked but the value is not convertible to a `double`.

Note: This exception is of kind "illegal state" rather than "illegal argument" because it is not caused by a bad argument. It is rather a consequence of invoking the wrong zero-argument method.

Since:
  GeoAPI 1.0
See Also:
  `ParameterValue.intValue()`, `ParameterValue.doubleValue(javax.units.Unit)`, Serialized Form

Constructor Summary
`InvalidParameterTypeException(String message, String parameterName)` Creates an exception with the specified message and parameter name.

Method Summary
`String` | `getParameterName()` Returns the parameter name.

Methods inherited from class Throwable
`fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString`

Methods inherited from class Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### InvalidParameterTypeException

    public InvalidParameterTypeException(String message,
                                         String parameterName)

  Creates an exception with the specified message and parameter name.

  Parameters:
    `message` - The detail message. The detail message is saved for later retrieval by the `Throwable.getMessage()` method.
    `parameterName` - The parameter name.

Method Detail

### getParameterName

    public String getParameterName()

  Returns the parameter name.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 1994-2008 Open Geospatial Consortium. All Rights Reserved.