master #59
|
@ -15,8 +15,6 @@ import org.jetbrains.annotations.NotNull;
|
||||||
*/
|
*/
|
||||||
public class QueryCommunityAPI {
|
public class QueryCommunityAPI {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private static String get(String geturl) throws IOException {
|
private static String get(String geturl) throws IOException {
|
||||||
URL url = new URL(geturl);
|
URL url = new URL(geturl);
|
||||||
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
|
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
|
||||||
|
@ -38,26 +36,25 @@ public class QueryCommunityAPI {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String community(String id, String baseURL ) throws IOException {
|
public static String community(String id, String baseURL) throws IOException {
|
||||||
|
|
||||||
return get(baseURL + id);
|
return get(baseURL + id);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String communityDatasource(String id, String baseURL ) throws IOException {
|
public static String communityDatasource(String id, String baseURL) throws IOException {
|
||||||
|
|
||||||
return get(baseURL + id + "/contentproviders");
|
return get(baseURL + id + "/contentproviders");
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String communityPropagationOrganization(String id, String baseURL ) throws IOException {
|
public static String communityPropagationOrganization(String id, String baseURL) throws IOException {
|
||||||
|
|
||||||
return get(baseURL + id + "/propagationOrganizations");
|
return get(baseURL + id + "/propagationOrganizations");
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String communityProjects(String id, String page, String size, String baseURL ) throws IOException {
|
public static String communityProjects(String id, String page, String size, String baseURL) throws IOException {
|
||||||
|
|
||||||
return get(baseURL + id + "/projects/" + page + "/" + size);
|
return get(baseURL + id + "/projects/" + page + "/" + size);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue