source: SRUClient/tags/SRUClient-0.9.4/src/main/java/eu/clarin/sru/client/SRUExplainResponse.java @ 5805

Last change on this file since 5805 was 5805, checked in by Oliver Schonefeld, 10 years ago
  • tag version 0.9.4
  • Property svn:eol-style set to native
File size: 1.7 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
21
22
23/**
24 * A response to a <em>explain</em> request.
25 */
26public final class SRUExplainResponse extends
27        SRUAbstractResponse<SRUExplainRequest> {
28    private final SRURecord record;
29
30
31    SRUExplainResponse(SRUExplainRequest request,
32            List<SRUDiagnostic> diagnostics,
33            List<SRUExtraResponseData> extraResponseData,
34            int totalBytesTransferred,
35            long timeTotal,
36            long timeQueued,
37            long timeNetwork,
38            long timeProcessing,
39            SRURecord record) {
40        super(request, diagnostics, extraResponseData, totalBytesTransferred,
41                timeTotal, timeQueued, timeNetwork, timeProcessing);
42        this.record = record;
43    }
44
45
46    /**
47     * Get the explain record.
48     *
49     * @return the explain record or <code>null</code>
50     */
51    public SRURecord getRecord() {
52        return record;
53    }
54
55
56    /**
57     * Check, if response contains a record.
58     *
59     * @return <code>true</code> of response contains a record,
60     *         <code>false</code> otherwise
61     */
62    public boolean hasRecord() {
63        return record != null;
64    }
65
66} // class SRUExplainResponse
Note: See TracBrowser for help on using the repository browser.