01: /*
02: * Copyright Aduna (http://www.aduna-software.com/) (c) 2007.
03: *
04: * Licensed under the Aduna BSD-style license.
05: */
06: package org.openrdf.query.resultio;
07:
08: import java.io.IOException;
09: import java.io.InputStream;
10:
11: /**
12: * A general interface for boolean query result parsers.
13: *
14: * @author Arjohn Kampman
15: */
16: public interface BooleanQueryResultParser {
17:
18: /**
19: * Gets the query result format that this parser can parse.
20: */
21: public BooleanQueryResultFormat getBooleanQueryResultFormat();
22:
23: /**
24: * Parses the data from the supplied InputStream.
25: *
26: * @param in
27: * The InputStream from which to read the data.
28: * @param baseURI
29: * The URI associated with the data in the InputStream.
30: * @throws IOException
31: * If an I/O error occurred while data was read from the InputStream.
32: * @throws QueryResultParseException
33: * If the parser has encountered an unrecoverable parse error.
34: */
35: public boolean parse(InputStream in) throws IOException,
36: QueryResultParseException;
37: }
|