KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > cyberneko > html > HTMLErrorReporter


1 /*
2  * (C) Copyright 2002-2005, Andy Clark. All rights reserved.
3  *
4  * This file is distributed under an Apache style license. Please
5  * refer to the LICENSE file for specific details.
6  */

7
8 package org.cyberneko.html;
9
10 import org.apache.xerces.xni.parser.XMLParseException;
11
12 /**
13  * Defines an error reporter for reporting HTML errors. There is no such
14  * thing as a fatal error in parsing HTML. I/O errors are fatal but should
15  * throw an <code>IOException</code> directly instead of reporting an error.
16  * <p>
17  * When used in a configuration, the error reporter instance should be
18  * set as a property with the following property identifier:
19  * <pre>
20  * "http://cyberneko.org/html/internal/error-reporter" in the
21  * </pre>
22  * Components in the configuration can query the error reporter using this
23  * property identifier.
24  * <p>
25  * <strong>Note:</strong>
26  * All reported errors are within the domain "http://cyberneko.org/html".
27  *
28  * @author Andy Clark
29  *
30  * @version $Id: HTMLErrorReporter.java,v 1.4 2005/02/14 03:56:54 andyc Exp $
31  */

32 public interface HTMLErrorReporter {
33     
34     //
35
// HTMLErrorReporter methods
36
//
37

38     /** Format message without reporting error. */
39     public String JavaDoc formatMessage(String JavaDoc key, Object JavaDoc[] args);
40
41     /** Reports a warning. */
42     public void reportWarning(String JavaDoc key, Object JavaDoc[] args) throws XMLParseException;
43
44     /** Reports an error. */
45     public void reportError(String JavaDoc key, Object JavaDoc[] args) throws XMLParseException;
46
47 } // interface HTMLErrorReporter
48
Popular Tags