Fixed APIs

master
Luca Frosini 2 years ago
parent 0d5c48ce35
commit e28e49438f

@ -28,7 +28,6 @@ public class Item extends GCatClient implements org.gcube.gcat.api.interfaces.It
super(enforcedServiceURL, ITEMS);
}
@Override
public int count() throws WebServiceException {
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.COUNT_PARAMETER, String.valueOf(true));
@ -58,7 +57,6 @@ public class Item extends GCatClient implements org.gcube.gcat.api.interfaces.It
return this.list(queryParams);
}
public String list(Map<String,String> queryParams) throws WebApplicationException {
return super.list(queryParams);
}
@ -124,6 +122,33 @@ public class Item extends GCatClient implements org.gcube.gcat.api.interfaces.It
super.delete(true, name);
return null;
}
public Void bulkDelete(Map<String,String> queryParams) throws WebServiceException{
try {
initRequest();
gxhttpStringRequest.queryParams(queryParams);
HttpURLConnection httpURLConnection = gxhttpStringRequest.delete();
parseHttpURLConnection(httpURLConnection);
return null;
}catch (WebApplicationException e) {
throw e;
}catch (Exception e) {
throw new WebApplicationException(e);
}
}
public Void bulkDelete(boolean purge) throws WebServiceException{
return null;
}
public Void bulkPurge() throws WebServiceException {
return null;
}
protected String moderate(String name, ModerationContent moderationContent) {
try {

Loading…
Cancel
Save