org.jasig.portal.properties
Class MissingPropertyException

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

public class MissingPropertyException
extends RuntimeException

An undeclared (Runtime) exception to be thrown by the PropertiesManager when a property is requested but cannot be found.

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
MissingPropertyException(String propertyName)
          Instantiate a MissingPropertyException for a particular missing property.
MissingPropertyException(String propertyName, boolean alreadyReported)
          Instantiate a MissingPropertyException for a particular missing property, indicating whether the throwing object has already thrown a MissingPropertyException for this property.
MissingPropertyException(String propertyName, boolean alreadyReported, Throwable cause)
          Instantiate a MissingPropertyException for a particular missing property, indicating whether the throwing object has already thrown a MissingPropertyException for this property, and supplying an underlying cause.
 
Method Summary
 String getMessage()
           
 String getPropertyName()
          Get the name of the missing property.
 boolean isAlreadyReported()
          Has the throwing object already reported (thrown a MissingPropertyException for) this particular missing property.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, 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

MissingPropertyException

public MissingPropertyException(String propertyName)
Instantiate a MissingPropertyException for a particular missing property.

Parameters:
propertyName - - the name of the property the value of which could not be found.

MissingPropertyException

public MissingPropertyException(String propertyName,
                                boolean alreadyReported)
Instantiate a MissingPropertyException for a particular missing property, indicating whether the throwing object has already thrown a MissingPropertyException for this property.

Parameters:
propertyName - name of missing property
alreadyReported - true if already reported

MissingPropertyException

public MissingPropertyException(String propertyName,
                                boolean alreadyReported,
                                Throwable cause)
Instantiate a MissingPropertyException for a particular missing property, indicating whether the throwing object has already thrown a MissingPropertyException for this property, and supplying an underlying cause.

Parameters:
propertyName - name of missing property
alreadyReported - true if already reported
cause - underlying cause
Method Detail

getMessage

public String getMessage()
Overrides:
getMessage in class Throwable

isAlreadyReported

public boolean isAlreadyReported()
Has the throwing object already reported (thrown a MissingPropertyException for) this particular missing property. Objects handling this exception might choose to predicate their logging detail on this property, for instance.

Returns:
Returns true this property has already been reported as missing by the throwing object.

getPropertyName

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

Returns:
Returns the name of the missing property.


Copyright © 2010 Jasig. All Rights Reserved.