Class JRValidationException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- net.sf.jasperreports.engine.JRException
-
- net.sf.jasperreports.engine.design.JRValidationException
-
- All Implemented Interfaces:
Serializable
public class JRValidationException extends JRException
An exception that contains a list ofreport validation faults
.- Author:
- Lucian Chirita (lucianc@users.sourceforge.net)
- See Also:
JRVerifier
, Serialized Form
-
-
Field Summary
-
Fields inherited from class net.sf.jasperreports.engine.JRException
EXCEPTION_MESSAGE_KEY_PREFIX, EXCEPTION_MESSAGES_BUNDLE
-
-
Constructor Summary
Constructors Constructor Description JRValidationException(String message, Object source)
Creates a validation exception containing a single fault.JRValidationException(String message, Collection<JRValidationFault> faults)
Create a validation exception.JRValidationException(Collection<JRValidationFault> faults)
Create an exception.JRValidationException(JRValidationFault fault)
Creates a validation exception containing a single fault.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static String
appendMessages(String header, Collection<JRValidationFault> faults)
Collection<JRValidationFault>
getFaults()
Returns the list ofvalidation faults
.-
Methods inherited from class net.sf.jasperreports.engine.JRException
getArgs, getMessage, getMessage, getMessageBundleName, getMessageKey, getMessageKeyPrefix, resolveMessage
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
JRValidationException
public JRValidationException(String message, Object source)
Creates a validation exception containing a single fault.- Parameters:
message
- the validation messagesource
- the validation source- See Also:
JRValidationFault
-
JRValidationException
public JRValidationException(JRValidationFault fault)
Creates a validation exception containing a single fault.- Parameters:
fault
- the fault
-
JRValidationException
public JRValidationException(Collection<JRValidationFault> faults)
Create an exception.- Parameters:
faults
- a list ofvalidation faults
-
JRValidationException
public JRValidationException(String message, Collection<JRValidationFault> faults)
Create a validation exception.- Parameters:
message
- the message to be used as header for the exception messagefaults
- a list ofvalidation faults
-
-
Method Detail
-
getFaults
public Collection<JRValidationFault> getFaults()
Returns the list ofvalidation faults
.- Returns:
- the list of
JRValidationFault
instances.
-
appendMessages
protected static String appendMessages(String header, Collection<JRValidationFault> faults)
-
-