public TileMapProvider(PersianEnglishItem provider, PersianEnglishItem mapType, Func <TileInfo, string> urlFunction, byte[] thumbnail) { this.MakeUrl = urlFunction; this._provider = provider; this._mapType = mapType; this._thumbnail = thumbnail; }
public TileMapProvider(string provider, string mapType, Func <TileInfo, string> urlFunction, byte[] thumbnail) : this(PersianEnglishItem.CreateUpperCasedEnglish(string.Empty, provider), PersianEnglishItem.CreateUpperCasedEnglish(string.Empty, mapType), urlFunction, thumbnail) { //this.MakeUrl = urlFunction; //this.Provider = new PersianEnglishItem(string.Empty, provider, Model.LanguageMode.English); //this.MapType = new PersianEnglishItem(string.Empty, mapType, Model.LanguageMode.English); }
public static TileMapProvider CreateFromXyzUrl(PersianEnglishItem provider, PersianEnglishItem mapType, string url, string thumbnailAddress) { var mapUrl = url.Replace("{x}", "{0}").Replace("{y}", "{1}").Replace("{z}", "{2}"); return(new TileMapProvider( provider, mapType, tile => string.Format(System.Globalization.CultureInfo.InvariantCulture, mapUrl, tile.ColumnNumber, tile.RowNumber, tile.ZoomLevel), ResourceHelper.ReadBinaryStreamFromResource(thumbnailAddress))); }
public static TileMapProvider CreateFromXyzUrlCharServer(PersianEnglishItem provider, PersianEnglishItem mapType, string url, string thumbnailAddress, string thumbnail72Address, int minServer = 0, int maxServer = 2) { var mapUrl = url.Replace("{x}", "{0}").Replace("{y}", "{1}").Replace("{z}", "{2}").Replace("{@server}", "{3}"); return(new TileMapProvider( provider, mapType, tile => string.Format(System.Globalization.CultureInfo.InvariantCulture, mapUrl, tile.ColumnNumber, tile.RowNumber, tile.ZoomLevel, GetServerCharacter(minServer, maxServer)), ResourceHelper.ReadBinaryStreamFromResource(thumbnailAddress)) { Thumbnail72 = ResourceHelper.ReadBinaryStreamFromResource(thumbnail72Address) }); }
public SpatialReferenceItem(Func <Point, Point> fromWgs84Geodetic, Func <double, string> toString, PersianEnglishItem titleItem, PersianEnglishItem subTitleItem, PersianEnglishItem xLabel, PersianEnglishItem yLabel) { this._fromWgs84Geodetic = fromWgs84Geodetic; this._toString = toString; this.TitleItem = titleItem; this.SubTitleItem = subTitleItem; this.XLabelItem = xLabel; this.YLabelItem = yLabel; }