예제 #1
0
        /// <inheritdoc />
        public void OnNext(Tile tile)
        {
            _trace.Info(TraceCategory, "loading tile: {0}", tile.ToString());

            MapDataAdapter.Add(tile);
            CoreLibrary.LoadTile(tile,
                                 MapDataAdapter.AdaptMesh,
                                 MapDataAdapter.AdaptElement,
                                 MapDataAdapter.AdaptError,
                                 _pathResolver);
            MapDataAdapter.Remove(tile);

            _trace.Info(TraceCategory, "tile loaded: {0}", tile.ToString());

            _tileObservers.ForEach(o => o.OnNext(tile));
        }
예제 #2
0
 /// <inheritdoc />
 public void Dispose()
 {
     MapDataAdapter.Clear();
 }
예제 #3
0
 /// <inheritdoc />
 public void Configure(IConfigSection configSection)
 {
     MapDataAdapter.UseTrace(_trace);
 }
예제 #4
0
 /// <summary> Subscribes on mesh/element data loaded events. </summary>
 public IDisposable Subscribe(IObserver <MapData> observer)
 {
     MapDataAdapter.Add(observer);
     _dataObservers.Add(observer);
     return(Disposable.Empty);
 }