示例#1
0
 private void AddGeofencesToMap()
 {
     foreach (var fence in _geofenceHelper.GetCurrentFences())
     {
         AddGeofenceToMap(fence);
     }
 }
示例#2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="GeofenceListingViewModel" /> class.
        /// </summary>
        /// <param name="geofenceHelper">The geofence helper.</param>
        /// <exception cref="System.ArgumentNullException">geofenceHelper</exception>
        public GeofenceListingViewModel([NotNull] GeofenceHelper geofenceHelper)
        {
            if (geofenceHelper == null)
            {
                throw new ArgumentNullException("geofenceHelper");
            }

            _geofenceHelper = geofenceHelper;


            if (!DesignMode.DesignModeEnabled)
            {
                _currentGeofences = new ObservableCollection <Geofence>(_geofenceHelper.GetCurrentFences());
            }
        }