public override bool Contains(TileIndex id)
 {
     return(cache.ContainsKey(id));
 }
 public void BeginSaveImage(TileIndex id, BitmapSource image, Stream stream)
 {
     cache[id] = image;
 }
예제 #3
0
 public abstract DataRect GetTileBounds(TileIndex id);
예제 #4
0
        private Stream BeginLoadStreamAsync(TileIndex id)
        {
            string imagePath = GetImagePath(id);

            return(new FileStream(imagePath, FileMode.Open, FileAccess.Read));
        }
 public override bool Contains(TileIndex id)
 {
     return(isNetworkAvailable && MinLevel <= id.Level && id.Level <= MaxLevel);
 }
 protected abstract string CreateRequestUriCore(TileIndex index);
 public string CreateRequestUri(TileIndex id)
 {
     return(CreateRequestUriCore(id));
 }
예제 #8
0
 public void Add(BitmapSource key, TileIndex value)
 {
     cache.Add(key, value);
 }
 protected virtual string GetNameByIndex(TileIndex index)
 {
     return(string.Concat(index.X.ToString(), "x", index.Y.ToString()));
 }