类 NotWritablePropertyException
- 所有已实现的接口:
Serializable
public class NotWritablePropertyException extends InvalidPropertyException
Exception thrown on an attempt to set the value of a property that is not writable (typically because there is no setter method).- 作者:
- Rod Johnson, Alef Arendsen, Arjen Poutsma
- 另请参阅:
- 序列化表格
构造器概要
构造器 构造器 说明 NotWritablePropertyException(Class<?> beanClass, String propertyName)
Create a new NotWritablePropertyException.NotWritablePropertyException(Class<?> beanClass, String propertyName, String msg)
Create a new NotWritablePropertyException.NotWritablePropertyException(Class<?> beanClass, String propertyName, String msg, String[] possibleMatches)
Create a new NotWritablePropertyException.NotWritablePropertyException(Class<?> beanClass, String propertyName, String msg, Throwable cause)
Create a new NotWritablePropertyException.
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 String[]
getPossibleMatches()
Return suggestions for actual bean property names that closely match the invalid property name, if any.从类继承的方法 org.springframework.beans.InvalidPropertyException
getBeanClass, getPropertyName
从类继承的方法 org.springframework.core.NestedRuntimeException
contains, getMessage, getMostSpecificCause, getRootCause
构造器详细资料
NotWritablePropertyException
public NotWritablePropertyException(Class<?> beanClass, String propertyName)
Create a new NotWritablePropertyException.- 参数:
beanClass
- the offending bean classpropertyName
- the offending property name
NotWritablePropertyException
public NotWritablePropertyException(Class<?> beanClass, String propertyName, String msg)
Create a new NotWritablePropertyException.- 参数:
beanClass
- the offending bean classpropertyName
- the offending property namemsg
- the detail message
NotWritablePropertyException
public NotWritablePropertyException(Class<?> beanClass, String propertyName, String msg, Throwable cause)
Create a new NotWritablePropertyException.- 参数:
beanClass
- the offending bean classpropertyName
- the offending property namemsg
- the detail messagecause
- the root cause
NotWritablePropertyException
public NotWritablePropertyException(Class<?> beanClass, String propertyName, String msg, String[] possibleMatches)
Create a new NotWritablePropertyException.- 参数:
beanClass
- the offending bean classpropertyName
- the offending property namemsg
- the detail messagepossibleMatches
- suggestions for actual bean property names that closely match the invalid property name
方法详细资料
getPossibleMatches
@Nullable public String[] getPossibleMatches()
Return suggestions for actual bean property names that closely match the invalid property name, if any.