KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > net > n3 > nanoxml > IXMLParser


1 /* IXMLParser.java NanoXML/Java
2  *
3  * $Revision: 1421 $
4  * $Date: 2006-03-12 17:32:32 +0100 (Sun, 12 Mar 2006) $
5  * $Name$
6  *
7  * This file is part of NanoXML 2 for Java.
8  * Copyright (C) 2001 Marc De Scheemaecker, All Rights Reserved.
9  *
10  * This software is provided 'as-is', without any express or implied warranty.
11  * In no event will the authors be held liable for any damages arising from the
12  * use of this software.
13  *
14  * Permission is granted to anyone to use this software for any purpose,
15  * including commercial applications, and to alter it and redistribute it
16  * freely, subject to the following restrictions:
17  *
18  * 1. The origin of this software must not be misrepresented; you must not
19  * claim that you wrote the original software. If you use this software in
20  * a product, an acknowledgment in the product documentation would be
21  * appreciated but is not required.
22  *
23  * 2. Altered source versions must be plainly marked as such, and must not be
24  * misrepresented as being the original software.
25  *
26  * 3. This notice may not be removed or altered from any source distribution.
27  */

28
29 package net.n3.nanoxml;
30
31 /**
32  * IXMLParser is the core parser of NanoXML.
33  *
34  * @author Marc De Scheemaecker
35  * @version $Name$, $Revision: 1421 $
36  */

37 public interface IXMLParser
38 {
39
40     /**
41      * Sets the reader from which the parser retrieves its data.
42      *
43      * @param reader the reader
44      */

45     public void setReader(IXMLReader reader);
46
47     /**
48      * Returns the reader from which the parser retrieves its data.
49      *
50      * @return the reader
51      */

52     public IXMLReader getReader();
53
54     /**
55      * Sets the builder which creates the logical structure of the XML data.
56      *
57      * @param builder the builder
58      */

59     public void setBuilder(IXMLBuilder builder);
60
61     /**
62      * Returns the builder which creates the logical structure of the XML data.
63      *
64      * @return the builder
65      */

66     public IXMLBuilder getBuilder();
67
68     /**
69      * Sets the validator that validates the XML data.
70      *
71      * @param validator the validator
72      */

73     public void setValidator(IXMLValidator validator);
74
75     /**
76      * Returns the validator that validates the XML data.
77      *
78      * @return the validator
79      */

80     public IXMLValidator getValidator();
81
82     /**
83      * Sets the entity resolver.
84      *
85      * @param resolver the non-null resolver
86      */

87     public void setResolver(IXMLEntityResolver resolver);
88
89     /**
90      * Returns the entity resolver.
91      *
92      * @return the non-null resolver
93      */

94     public IXMLEntityResolver getResolver();
95
96     /**
97      * Parses the data and lets the builder create the logical data structure.
98      *
99      * @return the logical structure built by the builder
100      *
101      * @throws net.n3.nanoxml.XMLException if an error occurred reading or parsing the data
102      */

103     public Object JavaDoc parse() throws XMLException;
104
105 }
106
Popular Tags