Class DistrictService
java.lang.Object
overit.geocallapp.utilities.rs.common.PrivateService
overit.geocallapp.wfm.locations.rs1.district.DistrictService
@RestController
@RequestMapping("territory/locations/r1/districts")
@Resource(logging=true)
public class DistrictService
extends PrivateService
Services to manage districts.
- Since:
- 16.0
- GCApi:
- rest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<DTODistrict> get(String id, Collection<String> fields) Retrieves the required district.org.springframework.http.ResponseEntity<PageResponse<DTODistrict>> getCollection(@Valid Page page, Collection<String> fields, String order, @Valid DTODistrictSearchFilter filter) Retrieve the all stored districts.
-
Constructor Details
-
DistrictService
public DistrictService()
-
-
Method Details
-
getCollection
@GetMapping(produces="application/json") public org.springframework.http.ResponseEntity<PageResponse<DTODistrict>> getCollection(@RequestParam("_page") @Valid @Valid Page page, @RequestParam(required=false,name="_fields") Collection<String> fields, @RequestParam(required=false,name="_order") String order, @Valid @Valid DTODistrictSearchFilter filter) throws DAValidateException, DAException Retrieve the all stored districts.DistrictSearchEvent- Parameters:
page- the required result pagefields- the collection of fields the response will containorder- the ordering fieldfilter- the specifiedDTODistrictSearchFilter- Returns:
- the response containing the current result page
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
get
@GetMapping(value="{districtId:[A-Za-z0-9-]+}", produces="application/json") public org.springframework.http.ResponseEntity<DTODistrict> get(@PathVariable("districtId") String id, @RequestParam(required=false,name="_fields") Collection<String> fields) throws DAValidateException, DAException Retrieves the required district.DistrictLoadEvent- Parameters:
id- district idfields- the collection of fields the response will contain- Returns:
- the response containing the required district
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-