Class MeterService
java.lang.Object
overit.geocallapp.utilities.rs.common.PrivateService
overit.geocallapp.wfm.accounts.rs1.meter.MeterService
@RestController
@RequestMapping("assets/accounts/r1/meters")
@Resource(logging=true)
public class MeterService
extends PrivateService
Service to manage meter
- Since:
- 16.0
- GCApi:
- rest
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity<DTOMeter> get(Long meterId, Collection<String> fields) Retrieves the requiredDTOMeterby calling theMeterLoadEvent.org.springframework.http.ResponseEntity<PageResponse<DTOMeter>> getCollection(@Valid Page page, Collection<String> fields, String order, @Valid DTOMeterFilter filter) Returns the collection of all the stored meters by calling theMeterSearchEvent.
-
Constructor Details
-
MeterService
public MeterService()
-
-
Method Details
-
getCollection
@GetMapping(produces="application/json") public org.springframework.http.ResponseEntity<PageResponse<DTOMeter>> getCollection(@RequestParam("_page") @Valid @Valid Page page, @RequestParam(required=false,name="_fields") Collection<String> fields, @RequestParam(required=false,name="_order") String order, @Valid @Valid DTOMeterFilter filter) throws DAValidateException, DAException Returns the collection of all the stored meters by calling theMeterSearchEvent.- Parameters:
page- thePagethat will contain the paginated resultfields- the collection of fields the response will containorder- the ordering fieldfilter- theDTOMeterFilter- Returns:
- the collection of
DTOMeter - Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-
get
@GetMapping(value="{meterId:[0-9]+}", produces="application/json") public org.springframework.http.ResponseEntity<DTOMeter> get(@PathVariable("meterId") Long meterId, @RequestParam(required=false,name="_fields") Collection<String> fields) throws DAValidateException, DAException Retrieves the requiredDTOMeterby calling theMeterLoadEvent.- Parameters:
meterId- the meter idfields- the collection of fields the response will contain- Returns:
- the response containing the loaded meter
- Throws:
DAValidateException- the DA validate exceptionDAException- the DA exception
-