geoportal-data-entry-app/src/main/java/org/gcube/portlets/user/geoportaldataentry/client/GeoportalDataEntryService.java

129 lines
3.9 KiB
Java
Raw Normal View History

2020-10-07 17:04:13 +02:00
package org.gcube.portlets.user.geoportaldataentry.client;
import java.util.List;
2020-12-01 18:15:13 +01:00
import org.gcube.application.geoportalcommon.shared.GeoNaItemRef;
2021-09-22 11:38:52 +02:00
import org.gcube.application.geoportalcommon.shared.products.ConcessioneDV;
import org.gcube.application.geoportalcommon.shared.products.paths.FileSetPathsDV;
2021-08-05 16:49:04 +02:00
import org.gcube.portlets.user.geoportaldataentry.client.ConstantsGeoPortalDataEntryApp.RECORD_TYPE;
import org.gcube.portlets.user.geoportaldataentry.shared.CommitReport;
import org.gcube.portlets.user.geoportaldataentry.shared.GeoNaFormDataObject;
import org.gcube.portlets.user.geoportaldataentry.shared.GeonaISConfig;
import org.gcube.portlets.user.geoportaldataentry.shared.ResultSetPaginatedData;
import org.gcube.portlets.user.geoportaldataentry.shared.SortFilter;
2021-09-29 18:27:22 +02:00
import org.gcube.portlets.widgets.mpformbuilder.shared.GenericDatasetBean;
2020-10-07 17:04:13 +02:00
import com.google.gwt.user.client.rpc.RemoteService;
import com.google.gwt.user.client.rpc.RemoteServiceRelativePath;
/**
* The client side stub for the RPC service.
2021-08-04 17:11:46 +02:00
*
* @author Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it
*
2021-08-05 16:49:04 +02:00
* Aug 4, 2021
2020-10-07 17:04:13 +02:00
*/
2020-10-22 16:50:14 +02:00
@RemoteServiceRelativePath("geoportaldataentryservice")
public interface GeoportalDataEntryService extends RemoteService {
2021-08-04 17:11:46 +02:00
/**
* Save geona data forms.
*
* @param listGeonaFormObjects the list geona form objects
* @return the commit report
* @throws Exception the exception
*/
CommitReport saveGeonaDataForms(List<GeoNaFormDataObject> listGeonaFormObjects) throws Exception;
2021-08-04 17:11:46 +02:00
/**
* Gets the geona init config.
*
* @return the geona init config
*/
GeonaISConfig getGeonaInitConfig();
2020-12-01 18:15:13 +01:00
2021-08-04 17:11:46 +02:00
/**
* Gets the links for.
*
2021-08-05 16:49:04 +02:00
* @param itemId the item id
2021-08-04 17:11:46 +02:00
* @param recordType the record type
* @return the links for
* @throws Exception the exception
*/
2021-08-05 16:49:04 +02:00
GeoNaItemRef getLinksFor(String itemId, RECORD_TYPE recordType) throws Exception;
2021-08-04 17:11:46 +02:00
/**
* Gets the list concessioni.
*
* @param start the start
* @param limit the limit
* @param filter the filter
2021-08-05 16:49:04 +02:00
* @param reloadFromService the reload from service
2021-08-04 17:11:46 +02:00
* @return the list concessioni
* @throws Exception the exception
*/
public ResultSetPaginatedData getListConcessioni(Integer start, Integer limit, SortFilter filter,
boolean reloadFromService) throws Exception;
2021-08-05 16:49:04 +02:00
/**
* Delete record.
*
* @param itemId the item id
2021-08-05 16:49:04 +02:00
* @param recordType the record type
* @return true, if successful
* @throws Exception the exception
2021-08-05 16:49:04 +02:00
*/
boolean deleteRecord(String itemId, RECORD_TYPE recordType) throws Exception;
/**
* Gets the JSON record.
*
* @param itemId the item id
* @param recordType the record type
* @return the JSON record
* @throws Exception the exception
*/
String getJSONRecord(String itemId, RECORD_TYPE recordType) throws Exception;
/**
* Update record.
*
* @param itemId the item id
* @param jsonUpdate the json update
* @param recordType the record type
* @return the concessione DV
* @throws Exception the exception
*/
2021-09-22 11:38:52 +02:00
ConcessioneDV updateRecord(String itemId, String jsonUpdate, RECORD_TYPE recordType) throws Exception;
2021-09-27 18:32:19 +02:00
/**
* Read file set paths.
*
* @return the file set paths DV
2021-09-27 18:32:19 +02:00
* @throws Exception the exception
*/
FileSetPathsDV readFileSetPaths() throws Exception;
2021-09-27 18:32:19 +02:00
/**
* Gets the record.
*
* @param itemId the item id
2021-09-27 18:32:19 +02:00
* @param recordType the record type
* @return the record
* @throws Exception the exception
*/
ConcessioneDV getRecord(String itemId, RECORD_TYPE recordType) throws Exception;
2021-09-29 18:27:22 +02:00
/**
* Update record.
*
* @param itemId the item id
* @param jsonUpdate the json update
* @param recordType the record type
* @return the updated JSON string representing the itemId
* @throws Exception the exception
*/
ConcessioneDV updateSectionForRecord(String itemId, String recordType, String section, int pathIndex,
GenericDatasetBean gDBean) throws Exception;
2020-10-07 17:04:13 +02:00
}