1
2
3
4
5
6
7 package org.astrogrid.tableserver.test;
8 import org.astrogrid.dataservice.queriers.Querier;
9 import org.astrogrid.dataservice.queriers.VotableInResults;
10
11 /***
12 * For testing only; returns a dummy votable
13 *
14 * @author M Hill
15 */
16
17 public class PrecannedResults extends VotableInResults {
18
19 private String id = null;
20
21 /***
22 * Create with some identifying mark (eg timestamp) if you want to distinguish
23 * it from other results. Loads example votable that should eb in the same
24 * package
25 */
26 public PrecannedResults(Querier parentQuerier, String someIdentifyingMark)
27 {
28 super(parentQuerier, PrecannedResults.class.getResourceAsStream("ExampleVotable.xml"));
29 this.id = someIdentifyingMark;
30
31
32
33 }
34
35 /*** Returns any old number */
36 public int getCount() {
37 return 15;
38 }
39
40
41
42 }