source: SRUClient/tags/SRUClient-0.9.3/src/main/java/eu/clarin/sru/client/SRUDefaultHandlerAdapter.java @ 5751

Last change on this file since 5751 was 5751, checked in by Oliver Schonefeld, 10 years ago
  • tag version 0.9.3
  • Property svn:eol-style set to native
File size: 3.1 KB
Line 
1/**
2 * This software is copyright (c) 2012-2014 by
3 *  - Institut fuer Deutsche Sprache (http://www.ids-mannheim.de)
4 * This is free software. You can redistribute it
5 * and/or modify it under the terms described in
6 * the GNU General Public License v3 of which you
7 * should have received a copy. Otherwise you can download
8 * it from
9 *
10 *   http://www.gnu.org/licenses/gpl-3.0.txt
11 *
12 * @copyright Institut fuer Deutsche Sprache (http://www.ids-mannheim.de)
13 *
14 * @license http://www.gnu.org/licenses/gpl-3.0.txt
15 *  GNU General Public License v3
16 */
17package eu.clarin.sru.client;
18
19import java.util.List;
20
21import javax.xml.stream.XMLStreamException;
22import javax.xml.stream.XMLStreamReader;
23
24
25/**
26 * Default base class for SRU client response handlers.
27 * <p>
28 * This class is available as a convenience base class for SRU client
29 * applications: it provides default implementations for all of the callbacks in
30 * the three request handler handler classes:
31 * </p>
32 * <ul>
33 *  <li>{@link SRUExplainHandler}</li>
34 *  <li>{@link SRUScanHandler}</li>
35 *  <li>{@link SRUSearchRetrieveHandler}</li>
36 * </ul>
37 * <p>
38 * Application writers can extend this class when they need to implement only
39 * part of an interface; parser writers can instantiate this class to provide
40 * default handlers when the application has not supplied its own.
41 * </p>
42 *
43 * @see SRUExplainHandler
44 * @see SRUScanHandler
45 * @see SRUSearchRetrieveHandler
46 */
47public class SRUDefaultHandlerAdapter implements SRUDefaultHandler {
48
49    @Override
50    public void onDiagnostics(List<SRUDiagnostic> diagnostics)
51            throws SRUClientException {
52    }
53
54    @Override
55    public void onRequestStatistics(int bytes, long millisTotal,
56            long millisNetwork, long millisParsing) {
57    }
58
59
60    @Override
61    public void onExtraResponseData(XMLStreamReader reader)
62            throws XMLStreamException, SRUClientException {
63    }
64
65
66    @Override
67    public void onStartTerms() throws SRUClientException {
68    }
69
70
71    @Override
72    public void onFinishTerms() throws SRUClientException {
73    }
74
75
76    @Override
77    public void onTerm(String value, int numberOfRecords, String displayTerm,
78            SRUWhereInList whereInList) throws SRUClientException {
79    }
80
81
82    @Override
83    public void onExtraTermData(String value, XMLStreamReader reader)
84            throws XMLStreamException, SRUClientException {
85    }
86
87
88    @Override
89    public void onStartRecords(int numberOfRecords, String resultSetId,
90            int resultSetIdleTime) throws SRUClientException {
91    }
92
93
94    @Override
95    public void onFinishRecords(int nextRecordPosition)
96            throws SRUClientException {
97    }
98
99
100    @Override
101    public void onRecord(String identifier, int position, SRURecordData data)
102            throws SRUClientException {
103    }
104
105
106    @Override
107    public void onSurrogateRecord(String identifier, int position,
108            SRUDiagnostic data) throws SRUClientException {
109    }
110
111
112    @Override
113    public void onExtraRecordData(String identifier, int position,
114            XMLStreamReader reader) throws XMLStreamException,
115            SRUClientException {
116    }
117
118} // class SRUDefaultHandler
Note: See TracBrowser for help on using the repository browser.