use of org.geosdi.geoplatform.gui.client.model.memento.save.storage.MementoFolderOriginalProperties in project geo-platform by geosdi.
the class SaveFolderPropertiesCommand method execute.
@Override
public SaveFolderPropertiesResponse execute(SaveFolderPropertiesRequest request, HttpServletRequest httpServletRequest) {
logger.info("##################### Executing {} Command", this.getClass().getSimpleName());
try {
this.sessionUtility.getLoggedAccount(httpServletRequest);
} catch (GPSessionTimeout timeout) {
throw new GeoPlatformException(timeout);
}
try {
MementoFolderOriginalProperties memento = request.getMementoFolderOriginalProperties();
geoPlatformServiceClient.saveFolderProperties(memento.getIdBaseElement(), memento.getName(), memento.isChecked(), memento.isExpanded());
} catch (ResourceNotFoundFault ex) {
SaveFolderPropertiesCommand.logger.error("Failed to save folder on LayerService: " + ex);
throw new GeoPlatformException(ex);
} catch (IllegalParameterFault ex) {
SaveFolderPropertiesCommand.logger.error("Failed to save folder on LayerService: " + ex);
throw new GeoPlatformException(ex);
}
logger.debug("#################### After sending project notification");
return new SaveFolderPropertiesResponse(Boolean.TRUE);
}
Aggregations