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.text;
07:
08: import java.io.OutputStream;
09:
10: import org.openrdf.query.resultio.BooleanQueryResultFormat;
11: import org.openrdf.query.resultio.BooleanQueryResultWriter;
12: import org.openrdf.query.resultio.BooleanQueryResultWriterFactory;
13:
14: /**
15: * A {@link BooleanQueryResultWriterFactory} for writers of plain text boolean
16: * query results.
17: *
18: * @author Arjohn Kampman
19: */
20: public class BooleanTextWriterFactory implements
21: BooleanQueryResultWriterFactory {
22:
23: /**
24: * Returns {@link BooleanQueryResultFormat#TEXT}.
25: */
26: public BooleanQueryResultFormat getBooleanQueryResultFormat() {
27: return BooleanQueryResultFormat.TEXT;
28: }
29:
30: /**
31: * Returns a new instance of BinaryQueryResultWriter.
32: */
33: public BooleanQueryResultWriter getWriter(OutputStream out) {
34: return new BooleanTextWriter(out);
35: }
36: }
|