Commit 6b128e203be2bab8ebd6dd94a9c0903ef79982ee

Authored by Nathanael Jourdane
1 parent e669c5d3
Exists in master

Add lasts Javadoc comments.

src/main/java/eu/omp/irap/vespa/epntapclient/EpnTapConnection.java
@@ -31,7 +31,7 @@ import eu.omp.irap.vespa.epntapclient.voresource.model.Resource; @@ -31,7 +31,7 @@ import eu.omp.irap.vespa.epntapclient.voresource.model.Resource;
31 import eu.omp.irap.vespa.epntapclient.votable.model.VOTABLE; 31 import eu.omp.irap.vespa.epntapclient.votable.model.VOTABLE;
32 import eu.omp.irap.vespa.votable.controller.VOTableController; 32 import eu.omp.irap.vespa.votable.controller.VOTableController;
33 import eu.omp.irap.vespa.votable.controller.VOTableException; 33 import eu.omp.irap.vespa.votable.controller.VOTableException;
34 -import eu.omp.irap.vespa.votable.controller.VOTableException.CantReadVOTableException; 34 +import eu.omp.irap.vespa.votable.controller.VOTableException.CantParseVOTableException;
35 import eu.omp.irap.vespa.votable.utils.StringJoiner; 35 import eu.omp.irap.vespa.votable.utils.StringJoiner;
36 import eu.omp.irap.vespa.votable.votabledata.VOTableData; 36 import eu.omp.irap.vespa.votable.votabledata.VOTableData;
37 37
@@ -134,7 +134,7 @@ public class EpnTapConnection implements EpnTapInterface { @@ -134,7 +134,7 @@ public class EpnTapConnection implements EpnTapInterface {
134 GranuleCtrl gc = new GranuleCtrl(data); 134 GranuleCtrl gc = new GranuleCtrl(data);
135 granules = gc.getGranules(); 135 granules = gc.getGranules();
136 } catch (ParseException e) { 136 } catch (ParseException e) {
137 - throw new CantReadVOTableException("Parsing error on a granule.", e); 137 + throw new CantParseVOTableException("Parsing error on a granule.", e);
138 } 138 }
139 return granules; 139 return granules;
140 } 140 }
@@ -152,7 +152,7 @@ public class EpnTapConnection implements EpnTapInterface { @@ -152,7 +152,7 @@ public class EpnTapConnection implements EpnTapInterface {
152 GranuleCtrl gc = new GranuleCtrl(data); 152 GranuleCtrl gc = new GranuleCtrl(data);
153 granules = gc.getGranules(); 153 granules = gc.getGranules();
154 } catch (ParseException e) { 154 } catch (ParseException e) {
155 - throw new CantReadVOTableException("Parsing error on a granule.", e); 155 + throw new CantParseVOTableException("Parsing error on a granule.", e);
156 } 156 }
157 return granules; 157 return granules;
158 } 158 }
src/main/java/eu/omp/irap/vespa/epntapclient/RequestCtrl.java
@@ -99,7 +99,7 @@ public class RequestCtrl { @@ -99,7 +99,7 @@ public class RequestCtrl {
99 Map<String, String> params = new HashMap<>(); 99 Map<String, String> params = new HashMap<>();
100 params.put("q", "\"" + begining + "\""); 100 params.put("q", "\"" + begining + "\"");
101 101
102 - String query = Network.buildQuery(RESOLVER_URL, params); 102 + String query = Network.buildGetRequest(RESOLVER_URL, params);
103 JsonObject root = Network.readJson(query); 103 JsonObject root = Network.readJson(query);
104 int count = Integer.parseInt(root.get("count").toString()); 104 int count = Integer.parseInt(root.get("count").toString());
105 String[] targetNames = new String[count]; 105 String[] targetNames = new String[count];
src/main/java/eu/omp/irap/vespa/epntapclient/voresource/VOResourceCtrl.java
@@ -91,7 +91,7 @@ public class VOResourceCtrl { @@ -91,7 +91,7 @@ public class VOResourceCtrl {
91 91
92 parameters.put("keywords", "datamodel:\"" + core.toString() + "\""); 92 parameters.put("keywords", "datamodel:\"" + core.toString() + "\"");
93 parameters.put("max", String.valueOf(MAX_VORESOURCES)); 93 parameters.put("max", String.valueOf(MAX_VORESOURCES));
94 - String query = Network.buildQuery(GET_JSONRESOURCES_URL, parameters); 94 + String query = Network.buildGetRequest(GET_JSONRESOURCES_URL, parameters);
95 try { 95 try {
96 ivoidResources = parseIvoidResources(Network.readJson(query)); 96 ivoidResources = parseIvoidResources(Network.readJson(query));
97 } catch (CantSendQueryException e) { 97 } catch (CantSendQueryException e) {
@@ -120,7 +120,7 @@ public class VOResourceCtrl { @@ -120,7 +120,7 @@ public class VOResourceCtrl {
120 "datamodel:\"" + core.toString() + "\" subjects:\"" + subjects + "\""); 120 "datamodel:\"" + core.toString() + "\" subjects:\"" + subjects + "\"");
121 parameters.put("max", String.valueOf(MAX_VORESOURCES)); 121 parameters.put("max", String.valueOf(MAX_VORESOURCES));
122 122
123 - String query = Network.buildQuery(GET_JSONRESOURCES_URL, parameters); 123 + String query = Network.buildGetRequest(GET_JSONRESOURCES_URL, parameters);
124 try { 124 try {
125 ivoidResources = parseIvoidResources(Network.readJson(query)); 125 ivoidResources = parseIvoidResources(Network.readJson(query));
126 } catch (CantSendQueryException e) { 126 } catch (CantSendQueryException e) {
@@ -144,7 +144,7 @@ public class VOResourceCtrl { @@ -144,7 +144,7 @@ public class VOResourceCtrl {
144 144
145 try { 145 try {
146 LOGGER.info("Trying to get VOResource '" + identifier + "'..."); 146 LOGGER.info("Trying to get VOResource '" + identifier + "'...");
147 - String query = Network.buildQuery(GET_VORESOURCE_URL, parameters); 147 + String query = Network.buildGetRequest(GET_VORESOURCE_URL, parameters);
148 voResourcePath = Network.saveQuery(query); 148 voResourcePath = Network.saveQuery(query);
149 } catch (CantSendQueryException e) { 149 } catch (CantSendQueryException e) {
150 throw new CantGetVOResourceException(GET_VORESOURCE_URL, e); 150 throw new CantGetVOResourceException(GET_VORESOURCE_URL, e);