org.jasig.portal.properties
Class BadPropertyException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by org.jasig.portal.properties.BadPropertyException
All Implemented Interfaces:
Serializable

public class BadPropertyException
extends RuntimeException

This is an undeclared (Runtime) exception to be thrown by the PropertiesManager when a property is requested but cannot be parsed and returned as the desired type.

Since:
uPortal 2.4
Version:
$Revision: 19776 $ $Date: 2010-01-14 16:17:21 -0600 (Thu, 14 Jan 2010) $
Author:
andrew.petro@yale.edu
See Also:
Serialized Form

Constructor Summary
BadPropertyException(String propertyName, String propertyValue, String desiredType)
          Instantiate a new BadPropertyException.
BadPropertyException(String propertyName, String propertyValue, String desiredType, Throwable cause)
          Instantiate a new BadPropertyException with the given underlying cause.
 
Method Summary
 String getDesiredType()
          Get the desired type as which the property could not be parsed.
 String getLocalizedMessage()
           
 String getMessage()
           
 String getPropertyName()
          Get the name of the bad property.
 String getPropertyValue()
          Get the actual value of the property.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BadPropertyException

public BadPropertyException(String propertyName,
                            String propertyValue,
                            String desiredType)
Instantiate a new BadPropertyException.

Parameters:
propertyName - - the name of the property
propertyValue - - the bad value of the property.
desiredType - - the name of the desired type which the value wasn't, making it bad.

BadPropertyException

public BadPropertyException(String propertyName,
                            String propertyValue,
                            String desiredType,
                            Throwable cause)
Instantiate a new BadPropertyException with the given underlying cause.

Parameters:
propertyName - - the name of the property
propertyValue - - the bad value of the property.
desiredType - - the name of the desired type which the value wasn't, making it bad.
cause - - underlying cause
Method Detail

getMessage

public String getMessage()
Overrides:
getMessage in class Throwable

getLocalizedMessage

public String getLocalizedMessage()
Overrides:
getLocalizedMessage in class Throwable

getDesiredType

public String getDesiredType()
Get the desired type as which the property could not be parsed.

Returns:
Returns the desiredType.

getPropertyName

public String getPropertyName()
Get the name of the bad property.

Returns:
Returns the propertyName.

getPropertyValue

public String getPropertyValue()
Get the actual value of the property.

Returns:
Returns the propertyValue.


Copyright © 2010 Jasig. All Rights Reserved.