이동하는 엔티티의 위치 업데이트

이동하는 도형 속성이 있는 엔티티의 위치를 업데이트하여 시간에 따른 이동을 반영할 수 있습니다. 이벤트가 발생하면 이동 도형 속성에 저장되는 엔티티의 이동 히스토리에 대해 이 위치 스냅샷을 추가할 수 있습니다.

다음 연산자를 사용하여 이동하는 엔티티의 현재 위치를 업데이트하십시오.

move <attribute> of <entity> to <geometry value>

도형의 현재 위치는 now의 값에 해당합니다.

다음 연산자를 사용하여 이동하는 도형의 위치를 특정 시간의 새 위치로 업데이트하십시오.

move <attribute> of <entity> to <geometry value> at <date & time>

다음 예에서 규칙을 수행하면 car 엔티티의 location 속성이 telemetry report 이벤트 시간에 car의 새 location으로 업데이트됩니다.

비즈니스 모델 정의:

a car is a business entity identified by a plate number with a model, a capacity (numeric), a color, a location (a moving geometry).

a telemetry report is a business event related to a car.
a telemetry report has a location (a point).

규칙:

when a new car telemetry report occurs
if   the location of 'the car' is not null
then   move the location of 'the car' to the location of this telemetry report 
   at the timestamp of this telemetry report;