GeofenceMonitor.GeofenceStateChanged 이벤트

정의

GeofenceMonitorGeofences 컬렉션에 있는 하나 이상의 Geofence 개체의 상태가 변경된 경우 발생합니다.

// Register
event_token GeofenceStateChanged(TypedEventHandler<GeofenceMonitor, IInspectable const&> const& handler) const;

// Revoke with event_token
void GeofenceStateChanged(event_token const* cookie) const;

// Revoke with event_revoker
GeofenceMonitor::GeofenceStateChanged_revoker GeofenceStateChanged(auto_revoke_t, TypedEventHandler<GeofenceMonitor, IInspectable const&> const& handler) const;
public event TypedEventHandler<GeofenceMonitor,object> GeofenceStateChanged;
function onGeofenceStateChanged(eventArgs) { /* Your code */ }
geofenceMonitor.addEventListener("geofencestatechanged", onGeofenceStateChanged);
geofenceMonitor.removeEventListener("geofencestatechanged", onGeofenceStateChanged);
- or -
geofenceMonitor.ongeofencestatechanged = onGeofenceStateChanged;
Public Custom Event GeofenceStateChanged As TypedEventHandler(Of GeofenceMonitor, Object) 

이벤트 유형

Windows 요구 사항

앱 기능
location

설명

이 이벤트는 앱이 실행 중이고 앱에서 등록된 지오펜스의 상태가 변경될 때 발생합니다. 이 이벤트는 ReadReports를 호출하여 가져온 컬렉션에 읽지 않은 보고서가 있는 경우 앱이 활성화될 때도 발생합니다. 이렇게 하면 일시 중단에서 돌아오는 앱이 큐에 읽지 않은 보고서가 있다는 알림을 받고 그에 따라 UI를 업데이트할 수 있습니다. 또한 인터넷 연결을 기다리거나 사용자가 있을 때까지 기다리는 등 SystemCondition으로 설정된 조건으로 인해 백그라운드 작업이 시작되지 않은 경우 앱에서 백그라운드에서 발생한 보고서를 읽을 수 있습니다.

적용 대상

추가 정보