Using renamed constant from gcat-api

master
Luca Frosini 2 years ago
parent f39a50e6fa
commit 136f740b61

@ -2,6 +2,12 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
# Changelog for gCube Catalogue (gCat) Client
## [v2.3.0-SNAPSHOT]
- Removed service discovery to to old service class
- Using renamed constant from gcat-api
## [v2.2.0]
- Added support to manage configurations [#22658]

@ -9,7 +9,7 @@
</parent>
<groupId>org.gcube.data-catalogue</groupId>
<artifactId>gcat-client</artifactId>
<version>2.2.0</version>
<version>2.3.0-SNAPSHOT</version>
<name>gCube Catalogue (gCat) Client</name>
<description>gCube Catalogue (gCat) Client is a library designed to interact with gCat Service exposed REST API</description>

@ -28,7 +28,7 @@ public class Group extends GCatClient implements org.gcube.gcat.api.interfaces.G
@Override
public int count() throws WebServiceException {
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.COUNT_PARAMETER, String.valueOf(true));
queryParams.put(GCatConstants.COUNT_QUERY_PARAMETER, String.valueOf(true));
String ret = this.list(queryParams);
ObjectMapper objectMapper = new ObjectMapper();
try {
@ -44,8 +44,8 @@ public class Group extends GCatClient implements org.gcube.gcat.api.interfaces.G
@Override
public String list(int limit, int offset) throws WebApplicationException {
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.LIMIT_PARAMETER, String.valueOf(limit));
queryParams.put(GCatConstants.OFFSET_PARAMETER, String.valueOf(offset));
queryParams.put(GCatConstants.LIMIT_QUERY_PARAMETER, String.valueOf(limit));
queryParams.put(GCatConstants.OFFSET_QUERY_PARAMETER, String.valueOf(offset));
return super.list(queryParams);
}

@ -30,7 +30,7 @@ public class Item extends GCatClient implements org.gcube.gcat.api.interfaces.It
public int count() throws WebServiceException {
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.COUNT_PARAMETER, String.valueOf(true));
queryParams.put(GCatConstants.COUNT_QUERY_PARAMETER, String.valueOf(true));
String ret = this.list(queryParams);
ObjectMapper objectMapper = new ObjectMapper();
try {
@ -52,8 +52,8 @@ public class Item extends GCatClient implements org.gcube.gcat.api.interfaces.It
@Override
public String list(int limit, int offset) throws WebApplicationException {
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.LIMIT_PARAMETER, String.valueOf(limit));
queryParams.put(GCatConstants.OFFSET_PARAMETER, String.valueOf(offset));
queryParams.put(GCatConstants.LIMIT_QUERY_PARAMETER, String.valueOf(limit));
queryParams.put(GCatConstants.OFFSET_QUERY_PARAMETER, String.valueOf(offset));
return this.list(queryParams);
}
@ -67,8 +67,8 @@ public class Item extends GCatClient implements org.gcube.gcat.api.interfaces.It
*/
public String list(int limit, int offset, String organizationName) throws WebApplicationException {
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.LIMIT_PARAMETER, String.valueOf(limit));
queryParams.put(GCatConstants.OFFSET_PARAMETER, String.valueOf(offset));
queryParams.put(GCatConstants.LIMIT_QUERY_PARAMETER, String.valueOf(limit));
queryParams.put(GCatConstants.OFFSET_QUERY_PARAMETER, String.valueOf(offset));
queryParams.put(GCatConstants.Q_KEY, String.format(GCatConstants.ORGANIZATION_FILTER_TEMPLATE, organizationName));
return super.list(queryParams);
}

@ -28,7 +28,7 @@ public class Organization extends GCatClient implements org.gcube.gcat.api.inter
@Override
public int count() throws WebServiceException {
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.COUNT_PARAMETER, String.valueOf(true));
queryParams.put(GCatConstants.COUNT_QUERY_PARAMETER, String.valueOf(true));
String ret = this.list(queryParams);
ObjectMapper objectMapper = new ObjectMapper();
try {
@ -44,8 +44,8 @@ public class Organization extends GCatClient implements org.gcube.gcat.api.inter
@Override
public String list(int limit, int offset) throws WebApplicationException {
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.LIMIT_PARAMETER, String.valueOf(limit));
queryParams.put(GCatConstants.OFFSET_PARAMETER, String.valueOf(offset));
queryParams.put(GCatConstants.LIMIT_QUERY_PARAMETER, String.valueOf(limit));
queryParams.put(GCatConstants.OFFSET_QUERY_PARAMETER, String.valueOf(offset));
return super.list(queryParams);
}

@ -31,7 +31,7 @@ public class Profile extends GCatClient implements org.gcube.gcat.api.interfaces
@Override
public int count() throws WebServiceException {
Map<String, String> queryParams = new HashMap<>();
queryParams.put(GCatConstants.COUNT_PARAMETER, String.valueOf(true));
queryParams.put(GCatConstants.COUNT_QUERY_PARAMETER, String.valueOf(true));
String ret = this.list(queryParams);
ObjectMapper objectMapper = new ObjectMapper();
try {

Loading…
Cancel
Save