Top Description Fields Constructors Methods
org.springframework.beans

public Class PropertyBatchUpdateException

extends BeansException
Class Inheritance
Annotations
@SuppressWarnings:serial
Imports
java.io.PrintStream, .PrintWriter, java.util.StringJoiner, org.springframework.lang.Nullable, org.springframework.util.Assert, .ObjectUtils

Combined exception, composed of individual PropertyAccessException instances. An object of this class is created at the beginning of the binding process, and errors added to it as necessary.

The binding process continues when it encounters application-level PropertyAccessExceptions, applying those changes that can be applied and storing rejected changes in an object of this class.

Authors
Rod Johnson, Juergen Hoeller
Since
18 April 2001

Field Summary

Modifier and TypeField and Description
private final PropertyAccessException[]
propertyAccessExceptions

List of PropertyAccessException objects.

Constructor Summary

AccessConstructor and Description
public
PropertyBatchUpdateException(PropertyAccessException[]
the List of PropertyAccessExceptions
propertyAccessExceptions
)

Create a new PropertyBatchUpdateException.

Method Summary

Modifier and TypeMethod and Description
public boolean
contains(Class<?>
the exception type to look for
exType
)

Overrides org.springframework.core.NestedRuntimeException.contains.

Check whether this exception contains an exception of the given type: either it is of the given class itself or it contains a nested cause of the given type.

public final int
getExceptionCount()

If this returns 0, no errors were encountered during binding.

public String
getMessage()

Overrides java.lang.Throwable.getMessage.

Returns the detail message string of this throwable.

public PropertyAccessException
getPropertyAccessException(String propertyName)

Return the exception for this field, or null if there isn't any.

public final PropertyAccessException[]
getPropertyAccessExceptions()

Return an array of the propertyAccessExceptions stored in this object.

public void
printStackTrace(PrintStream
PrintStream to use for output
ps
)

Overrides java.lang.Throwable.printStackTrace.

Prints this throwable and its backtrace to the specified print stream.

public void
printStackTrace(PrintWriter
PrintWriter to use for output
pw
)

Overrides java.lang.Throwable.printStackTrace.

Prints this throwable and its backtrace to the specified print writer.

public String
toString()

Overrides java.lang.Throwable.toString.

Returns a short description of this throwable.

Field Detail

propertyAccessExceptionsback to summary
private final PropertyAccessException[] propertyAccessExceptions

List of PropertyAccessException objects.

Constructor Detail

PropertyBatchUpdateExceptionback to summary
public PropertyBatchUpdateException(PropertyAccessException[] propertyAccessExceptions)

Create a new PropertyBatchUpdateException.

Parameters
propertyAccessExceptions:PropertyAccessException[]

the List of PropertyAccessExceptions

Method Detail

containsback to summary
public boolean contains(Class<?> exType)

Overrides org.springframework.core.NestedRuntimeException.contains.

Doc from org.springframework.core.NestedRuntimeException.contains.

Check whether this exception contains an exception of the given type: either it is of the given class itself or it contains a nested cause of the given type.

Parameters
exType:Class<?>

the exception type to look for

Returns:boolean

whether there is a nested exception of the specified type

Annotations
@Override
getExceptionCountback to summary
public final int getExceptionCount()

If this returns 0, no errors were encountered during binding.

getMessageback to summary
public String getMessage()

Overrides java.lang.Throwable.getMessage.

Doc from java.lang.Throwable.getMessage.

Returns the detail message string of this throwable.

Returns:String

the detail message string of this Throwable instance (which may be null).

Annotations
@Override
getPropertyAccessExceptionback to summary
public PropertyAccessException getPropertyAccessException(String propertyName)

Return the exception for this field, or null if there isn't any.

Annotations
@Nullable
getPropertyAccessExceptionsback to summary
public final PropertyAccessException[] getPropertyAccessExceptions()

Return an array of the propertyAccessExceptions stored in this object.

Will return the empty array (not null) if there were no errors.

printStackTraceback to summary
public void printStackTrace(PrintStream ps)

Overrides java.lang.Throwable.printStackTrace.

Doc from java.lang.Throwable.printStackTrace.

Prints this throwable and its backtrace to the specified print stream.

Parameters
ps:PrintStream

PrintStream to use for output

Annotations
@Override
printStackTraceback to summary
public void printStackTrace(PrintWriter pw)

Overrides java.lang.Throwable.printStackTrace.

Doc from java.lang.Throwable.printStackTrace.

Prints this throwable and its backtrace to the specified print writer.

Parameters
pw:PrintWriter

PrintWriter to use for output

Annotations
@Override
toStringback to summary
public String toString()

Overrides java.lang.Throwable.toString.

Doc from java.lang.Throwable.toString.

Returns a short description of this throwable. The result is the concatenation of:

  • the name of the class of this object
  • ": " (a colon and a space)
  • the result of invoking this object's getLocalizedMessage method
If getLocalizedMessage returns null, then just the class name is returned.
Returns:String

a string representation of this throwable.

Annotations
@Override