Mapsui.Tests.Common.SampleTileProvider.GetTileStream C# (CSharp) Method

GetTileStream() private static method

private static GetTileStream ( BruTile.TileIndex index ) : Stream
index BruTile.TileIndex
return Stream
        private static Stream GetTileStream(TileIndex index)
        {
            var path = $"Mapsui.Tests.Common.Resources.SampleTiles.{index.Level}_{index.Col}_{index.Row}.png";
            var data = typeof(Utilities).GetTypeInfo().Assembly.GetManifestResourceStream(path);
            if (data == null) throw new Exception($"Resource could not be found: {path}");
            return data;
        }