Add interfaces for content parser.
[arachne.git] / src / net / pterodactylus / arachne / parser / Parser.java
1 /*
2  * © 2009 David ‘Bombe’ Roden
3  */
4 package net.pterodactylus.arachne.parser;
5
6 import java.io.InputStream;
7
8 /**
9  * Interface for a parser. A parser understands the format it should parse and
10  * can generate events based on the parsed content.
11  *
12  * @see ParserListener
13  * @author David ‘Bombe’ Roden <bombe@pterodactylus.net>
14  */
15 public interface Parser {
16
17         /**
18          * Parses the given input stream and sends events to the given listener.
19          *
20          * @param parserListener
21          *            The listener to send events to
22          * @param inputStream
23          *            The input stream to parse
24          */
25         public void parse(ParserListener parserListener, InputStream inputStream);
26
27 }