48 * Modifying the Java content tree within your event handler is undefined
49 * by the specification and may result in unexpected behaviour.
50 *
51 * <p>
52 * Failing to return false from the <tt>handleEvent</tt> method after
53 * encountering a fatal error is undefined by the specification and may result
54 * in unexpected behavior.
55 *
56 * <p>
57 * <b>Default Event Handler</b>
58 * <blockquote>
59 * See: <a href="Validator.html#defaulthandler">Validator javadocs</a>
60 * </blockquote>
61 *
62 * @author <ul><li>Ryan Shoemaker, Sun Microsystems, Inc.</li><li>Kohsuke Kawaguchi, Sun Microsystems, Inc.</li><li>Joe Fialli, Sun Microsystems, Inc.</li></ul>
63 * @see Unmarshaller
64 * @see Validator
65 * @see Marshaller
66 * @see ValidationEvent
67 * @see javax.xml.bind.util.ValidationEventCollector
68 * @since JAXB1.0
69 */
70 public interface ValidationEventHandler {
71 /**
72 * Receive notification of a validation warning or error.
73 *
74 * The ValidationEvent will have a
75 * {@link ValidationEventLocator ValidationEventLocator} embedded in it that
76 * indicates where the error or warning occurred.
77 *
78 * <p>
79 * If an unchecked runtime exception is thrown from this method, the JAXB
80 * provider will treat it as if the method returned false and interrupt
81 * the current unmarshal, validate, or marshal operation.
82 *
83 * @param event the encapsulated validation event information. It is a
84 * provider error if this parameter is null.
85 * @return true if the JAXB Provider should attempt to continue the current
86 * unmarshal, validate, or marshal operation after handling this
87 * warning/error, false if the provider should terminate the current
88 * operation with the appropriate <tt>UnmarshalException</tt>,
|
48 * Modifying the Java content tree within your event handler is undefined
49 * by the specification and may result in unexpected behaviour.
50 *
51 * <p>
52 * Failing to return false from the <tt>handleEvent</tt> method after
53 * encountering a fatal error is undefined by the specification and may result
54 * in unexpected behavior.
55 *
56 * <p>
57 * <b>Default Event Handler</b>
58 * <blockquote>
59 * See: <a href="Validator.html#defaulthandler">Validator javadocs</a>
60 * </blockquote>
61 *
62 * @author <ul><li>Ryan Shoemaker, Sun Microsystems, Inc.</li><li>Kohsuke Kawaguchi, Sun Microsystems, Inc.</li><li>Joe Fialli, Sun Microsystems, Inc.</li></ul>
63 * @see Unmarshaller
64 * @see Validator
65 * @see Marshaller
66 * @see ValidationEvent
67 * @see javax.xml.bind.util.ValidationEventCollector
68 * @since 1.6, JAXB 1.0
69 */
70 public interface ValidationEventHandler {
71 /**
72 * Receive notification of a validation warning or error.
73 *
74 * The ValidationEvent will have a
75 * {@link ValidationEventLocator ValidationEventLocator} embedded in it that
76 * indicates where the error or warning occurred.
77 *
78 * <p>
79 * If an unchecked runtime exception is thrown from this method, the JAXB
80 * provider will treat it as if the method returned false and interrupt
81 * the current unmarshal, validate, or marshal operation.
82 *
83 * @param event the encapsulated validation event information. It is a
84 * provider error if this parameter is null.
85 * @return true if the JAXB Provider should attempt to continue the current
86 * unmarshal, validate, or marshal operation after handling this
87 * warning/error, false if the provider should terminate the current
88 * operation with the appropriate <tt>UnmarshalException</tt>,
|