类 PropertyAccessException
- java.lang.Object
- java.lang.Throwable
- java.lang.Exception
- java.lang.RuntimeException
- org.springframework.core.NestedRuntimeException
- org.springframework.beans.BeansException
- org.springframework.beans.PropertyAccessException
- 所有已实现的接口:
Serializable
,ErrorCoded
public abstract class PropertyAccessException extends BeansException implements ErrorCoded
Superclass for exceptions related to a property access, such as type mismatch or invocation target exception.- 作者:
- Rod Johnson, Juergen Hoeller
- 另请参阅:
- 序列化表格
构造器概要
构造器 构造器 说明 PropertyAccessException(PropertyChangeEvent propertyChangeEvent, String msg, Throwable cause)
Create a new PropertyAccessException.PropertyAccessException(String msg, Throwable cause)
Create a new PropertyAccessException without PropertyChangeEvent.
方法概要
所有方法 实例方法 抽象方法 具体方法 修饰符和类型 方法 说明 abstract String
getErrorCode()
Return a corresponding error code for this type of exception.PropertyChangeEvent
getPropertyChangeEvent()
Return the PropertyChangeEvent that resulted in the problem.String
getPropertyName()
Return the name of the affected property, if available.Object
getValue()
Return the affected value that was about to be set, if any.从类继承的方法 org.springframework.beans.BeansException
equals, hashCode
从类继承的方法 org.springframework.core.NestedRuntimeException
contains, getMessage, getMostSpecificCause, getRootCause
构造器详细资料
PropertyAccessException
public PropertyAccessException(PropertyChangeEvent propertyChangeEvent, String msg, Throwable cause)
Create a new PropertyAccessException.- 参数:
propertyChangeEvent
- the PropertyChangeEvent that resulted in the problemmsg
- the detail messagecause
- the root cause
PropertyAccessException
public PropertyAccessException(String msg, Throwable cause)
Create a new PropertyAccessException without PropertyChangeEvent.- 参数:
msg
- the detail messagecause
- the root cause
方法详细资料
getPropertyChangeEvent
public PropertyChangeEvent getPropertyChangeEvent()
Return the PropertyChangeEvent that resulted in the problem.May be
null
; only available if an actual bean property was affected.
getPropertyName
public String getPropertyName()
Return the name of the affected property, if available.
getErrorCode
public abstract String getErrorCode()
Return a corresponding error code for this type of exception.- 指定者:
getErrorCode
在接口中ErrorCoded
- 返回:
- a String error code associated with this failure, or
null
if not error-coded