Class GeoServiceAdminController
java.lang.Object
org.tailormap.api.controller.admin.GeoServiceAdminController
-
Constructor Summary
ConstructorsConstructorDescriptionGeoServiceAdminController(GeoServiceRepository geoServiceRepository, org.springframework.data.rest.webmvc.support.RepositoryEntityLinks repositoryEntityLinks, GeoServiceHelper geoServiceHelper, CatalogRepository catalogRepository) -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<?> org.springframework.http.ResponseEntity<org.springframework.hateoas.EntityModel<GeoService>> createGeoService(@Valid GeoService geoService, String catalogNodeId) Create a new GeoService and attach it to a catalog node.org.springframework.http.ResponseEntity<?> handleException(org.springframework.web.server.ResponseStatusException ex) org.springframework.http.ResponseEntity<?> org.springframework.http.ResponseEntity<List<GeoServiceLayer>> refreshCapabilities(String id, jakarta.servlet.http.HttpServletResponse httpServletResponse)
-
Constructor Details
-
GeoServiceAdminController
public GeoServiceAdminController(GeoServiceRepository geoServiceRepository, org.springframework.data.rest.webmvc.support.RepositoryEntityLinks repositoryEntityLinks, GeoServiceHelper geoServiceHelper, CatalogRepository catalogRepository)
-
-
Method Details
-
badRequestException
@ExceptionHandler({IllegalArgumentException.class,UnsupportedOperationException.class,URISyntaxException.class,UnknownHostException.class}) public org.springframework.http.ResponseEntity<?> badRequestException(Exception ex) -
internalServerError
@ExceptionHandler({org.geotools.ows.ServiceException.class,IOException.class}) public org.springframework.http.ResponseEntity<?> internalServerError(Exception ex) -
handleException
@ExceptionHandler(org.springframework.web.server.ResponseStatusException.class) public org.springframework.http.ResponseEntity<?> handleException(org.springframework.web.server.ResponseStatusException ex) -
refreshCapabilities
@PostMapping(path="${tailormap-api.admin.base-path}/geo-services/{id}/refresh-capabilities") @ResponseStatus public org.springframework.http.ResponseEntity<List<GeoServiceLayer>> refreshCapabilities(@PathVariable String id, jakarta.servlet.http.HttpServletResponse httpServletResponse) throws IOException, IllegalArgumentException, URISyntaxException, org.geotools.ows.ServiceException, UnsupportedOperationException - Throws:
IOExceptionIllegalArgumentExceptionURISyntaxExceptionorg.geotools.ows.ServiceExceptionUnsupportedOperationException
-
createGeoService
@PostMapping(path="${tailormap-api.admin.base-path}/geo-services/new") @Transactional public org.springframework.http.ResponseEntity<org.springframework.hateoas.EntityModel<GeoService>> createGeoService(@RequestBody @Valid @Valid GeoService geoService, @RequestParam String catalogNodeId) throws org.geotools.ows.ServiceException, URISyntaxException, IOException, org.springframework.orm.ObjectOptimisticLockingFailureException Create a new GeoService and attach it to a catalog node.- Parameters:
geoService- the GeoService to createcatalogNodeId- the node this service is to be attached to- Returns:
- the created GeoService as a HATEOAS resource with a link to the resource
- Throws:
org.geotools.ows.ServiceException- if there is an error loading the service capabilitiesURISyntaxException- if the URL is invalidIOException- if there is an error loading the service capabilitiesorg.springframework.orm.ObjectOptimisticLockingFailureException- if there is a concurrent modification likely of the catalog
-