1
2
3
4
5
6
7
8
9
10
11 package org.astrogrid.dataservice.service.cone;
12
13 import java.io.IOException;
14 import org.astrogrid.cfg.ConfigFactory;
15 import org.astrogrid.dataservice.metadata.VoResourcePlugin;
16 import org.astrogrid.dataservice.metadata.v0_10.VoResourceSupport;
17 import org.astrogrid.dataservice.service.ServletHelper;
18 import org.astrogrid.query.Query;
19
20 /*** Returns Registry resources for a service type that indicates that this
21 * service can provide cone searches
22 */
23 public class ConeResources extends VoResourceSupport implements VoResourcePlugin {
24
25 /***
26 * Returns ServiceType for cone search
27 */
28 public String getVoResource() throws IOException {
29
30 String cone =
31 makeVoResourceElement("ServiceType", "")+
32 makeCore("cone")+
33
34
35
36 "<Capability xmlns:q1='http://www.ivoa.net/xml/ConeSearch/v0.2' xsi:type='q1:ConeSearchType'>"+
37 " <q1:MaxSR>180</q1:MaxSR>"+
38 " <q1:MaxRecords>"+ConfigFactory.getCommonConfig().getString(Query.MAX_RETURN_KEY,"0")+"</q1:MaxRecords>"+
39 " <q1:Verbosity>false</q1:Verbosity>"+
40 "</Capability>"+
41 "<Interface>"+
42 " <Invocation>Custom</Invocation>"+
43 " <AccessURL>"+ServletHelper.getUrlStem()+"cone/SubmitCone?</AccessURL>"+
44 "</Interface>"+
45 "</"+VORESOURCE_ELEMENT+">";
46
47 return cone;
48 }
49
50
51 }
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79