@CrossOrigin
@RestController
@RequestMapping(value="/movements/aggregated")
public class AggregatedMovementController
extends java.lang.Object
Constructor and Description |
---|
AggregatedMovementController(AggregatedMovementService aggregatedMovementService) |
Modifier and Type | Method and Description |
---|---|
long |
getMovementCountByAreaId(java.util.UUID monitoredAreaID,
java.time.Instant since,
java.time.Instant until,
@Min(value=0L) double minVelocity,
@Min(value=0L) double maxVelocity)
Returns the number of movements that would be returned by a call to
getMovementsByAreaId
with the same arguments |
java.lang.Iterable<MovementView> |
getMovementsByAreaId(java.util.UUID monitoredAreaID,
java.time.Instant since,
java.time.Instant until,
@Min(value=0L) double minVelocity,
@Min(value=0L) double maxVelocity)
Returns movements filtered by the given criteria
|
MinMax |
getVelocityRangeByArea(java.util.UUID monitoredAreaID,
java.time.Instant since,
java.time.Instant until)
Returns the smallest and larges velocity recorded in the given area.
|
@Autowired public AggregatedMovementController(AggregatedMovementService aggregatedMovementService)
@GetMapping(value="") public java.lang.Iterable<MovementView> getMovementsByAreaId(@RequestParam(value="area_id") java.util.UUID monitoredAreaID, @RequestParam(value="since",required=false) @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssZZZ") java.time.Instant since, @RequestParam(value="until",required=false) @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssZZZ") java.time.Instant until, @RequestParam(value="min_velocity",required=false,defaultValue="0") @Min(value=0L) @Min(value=0L) double minVelocity, @RequestParam(value="max_velocity",required=false,defaultValue="-1") @Min(value=0L) @Min(value=0L) double maxVelocity)
monitoredAreaID
- the ID of the monitored are who movements should be returnedsince
- the time since when movements should be returneduntil
- the time until when movements should be returnedminVelocity
- minimum speed in pixels per second, points at which the speed was
lower will not be returnedmaxVelocity
- maximum speed in pixels per second (-1 for unlimited), points at
which the speed was higher will not be returned@GetMapping(value="/count") public long getMovementCountByAreaId(@RequestParam(value="area_id") java.util.UUID monitoredAreaID, @RequestParam(value="since",required=false) @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssZZZ") java.time.Instant since, @RequestParam(value="until",required=false) @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssZZZ") java.time.Instant until, @RequestParam(value="min_velocity",required=false,defaultValue="0") @Min(value=0L) @Min(value=0L) double minVelocity, @RequestParam(value="max_velocity",required=false,defaultValue="-1") @Min(value=0L) @Min(value=0L) double maxVelocity)
getMovementsByAreaId
with the same argumentsmonitoredAreaID
- the ID of the monitored are who movements should be returnedsince
- the time since when movements should be returneduntil
- the time until when movements should be returnedminVelocity
- minimum speed in pixels per second, points at which the speed was
lower will not be returnedmaxVelocity
- maximum speed in pixels per second (-1 for unlimited), points at
which the speed was higher will not be returned@GetMapping(value="/velocity_range") public MinMax getVelocityRangeByArea(@RequestParam(value="area_id") java.util.UUID monitoredAreaID, @RequestParam(value="since",required=false) @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssZZZ") java.time.Instant since, @RequestParam(value="until",required=false) @DateTimeFormat(pattern="yyyy-MM-dd\'T\'HH:mm:ssZZZ") java.time.Instant until)
monitoredAreaID
- the id of the monitored areasince
- the time since when movements should be returneduntil
- the time until when movements should be returned