Skip to content

Commit

Permalink
2.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
mmomtchev committed Feb 26, 2024
1 parent 0db123b commit 8cdd966
Show file tree
Hide file tree
Showing 3 changed files with 71 additions and 45 deletions.
110 changes: 68 additions & 42 deletions docs/API.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,17 @@
* [MBTilesVectorOptions][13]
* [sqlWorkers][14]
* [layers][15]
* [pool][16]
* [SQLOptions][17]
* [url][18]
* [sqlWorkers][19]
* [maxSqlPageSize][20]
* [sqlCacheSize][21]
* [backendType][22]
* [importMBTiles][23]
* [Parameters][24]
* [minZoom][16]
* [maxZoom][17]
* [pool][18]
* [SQLOptions][19]
* [url][20]
* [sqlWorkers][21]
* [maxSqlPageSize][22]
* [sqlCacheSize][23]
* [backendType][24]
* [importMBTiles][25]
* [Parameters][26]

## MBTilesRasterSource

Expand All @@ -41,7 +43,7 @@ automatically garbage-collect unless the dispose() method
is invoked.
If you need to dispose a map that can potentially contain
MBTilesSource objects, check loadExample() in
[https://github.com/mmomtchev/ol-mbtiles/blob/main/examples/index.ts#L15][25]
[https://github.com/mmomtchev/ol-mbtiles/blob/main/examples/index.ts#L15][27]

### Parameters

Expand All @@ -57,25 +59,29 @@ Options for creating a MBTilesRasterSource

Number of parallel workers to use for retrieving tiles, @default 4

Type: [number][26]
Type: [number][28]

### layers

List of layer names to selectively include, @default everything

Type: [Array][27]<[string][28]>
Type: [Array][29]<[string][30]>

### minZoom

Alternative method of specifying minZoom, mutually exclusive with tileGrid, requires explicit projection
Alternative method of specifying minZoom, mutually exclusive with tileGrid, requires explicit projection.
This refers to the available zoom levels of the tiled data and it is different from the OpenLayers minZoom
parameter that applies to the layer.

Type: [number][26]
Type: [number][28]

### maxZoom

Alternative method of specifying minZoom, mutually exclusive with tileGrid, requires explicit projection
Alternative method of specifying maxZoom, mutually exclusive with tileGrid, requires explicit projection
This refers to the available zoom levels of the tiled data and it is different from the OpenLayers maxZoom
parameter that applies to the layer.

Type: [number][26]
Type: [number][28]

### tileGrid

Expand All @@ -87,13 +93,13 @@ Type: TileGrid

Optional already open SQLiteHTTP pool (mutually exclusive with url)

Type: [Promise][29]\<SQLiteHTTPPool>
Type: [Promise][31]\<SQLiteHTTPPool>

### mime

Optional MIME type for loaded tiles (see [https://github.com/mmomtchev/ol-mbtiles/issues/68][30])
Optional MIME type for loaded tiles (see [https://github.com/mmomtchev/ol-mbtiles/issues/68][32])

Type: [string][28]
Type: [string][30]

## MBTilesVectorSource

Expand All @@ -109,7 +115,7 @@ automatically garbage-collect unless the dispose() method
is invoked.
If you need to dispose a map that can potentially contain
MBTilesSource objects, check loadExample() in
[https://github.com/mmomtchev/ol-mbtiles/blob/main/examples/index.ts#L15][25]
[https://github.com/mmomtchev/ol-mbtiles/blob/main/examples/index.ts#L15][27]

### Parameters

Expand All @@ -125,19 +131,35 @@ Options for creating a MBTilesVectorSource

Number of parallel workers to use for retrieving tiles, @default 4

Type: [number][26]
Type: [number][28]

### layers

List of layer names to selectively include, @default everything

Type: [Array][27]<[string][28]>
Type: [Array][29]<[string][30]>

### minZoom

Minimum available zoom level.
This refers to the available zoom levels of the tiled data and it is different from the OpenLayers minZoom
parameter that applies to the layer.

Type: [number][28]

### maxZoom

Maximum available zoom level.
This refers to the available zoom levels of the tiled data and it is different from the OpenLayers maxZoom
parameter that applies to the layer.

Type: [number][28]

### pool

Optional already open SQLiteHTTP pool (mutually exclusive with url)

Type: [Promise][29]\<SQLiteHTTPPool>
Type: [Promise][31]\<SQLiteHTTPPool>

## SQLOptions

Expand All @@ -147,25 +169,25 @@ Shared options for all MBTiles

URL of the remote MBTiles source

Type: [string][28]
Type: [string][30]

### sqlWorkers

Number of parallel workers to use for retrieving tiles, @default 4

Type: [number][26]
Type: [number][28]

### maxSqlPageSize

Maximum expected page size in bytes for SQLite3 files, @default 4096

Type: [number][26]
Type: [number][28]

### sqlCacheSize

Memory to use for SQLite cache in KB, @default 4096

Type: [number][26]
Type: [number][28]

### backendType

Expand Down Expand Up @@ -214,32 +236,36 @@ Returns **([MBTilesRasterOptions][3] | [MBTilesVectorOptions][13])**&#x20;

[15]: #layers-1

[16]: #pool-1
[16]: #minzoom-1

[17]: #maxzoom-1

[18]: #pool-1

[17]: #sqloptions
[19]: #sqloptions

[18]: #url
[20]: #url

[19]: #sqlworkers-2
[21]: #sqlworkers-2

[20]: #maxsqlpagesize
[22]: #maxsqlpagesize

[21]: #sqlcachesize
[23]: #sqlcachesize

[22]: #backendtype
[24]: #backendtype

[23]: #importmbtiles
[25]: #importmbtiles

[24]: #parameters-2
[26]: #parameters-2

[25]: https://github.com/mmomtchev/ol-mbtiles/blob/main/examples/index.ts#L15
[27]: https://github.com/mmomtchev/ol-mbtiles/blob/main/examples/index.ts#L15

[26]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number
[28]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Number

[27]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array
[29]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array

[28]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String
[30]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String

[29]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise
[31]: https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Promise

[30]: https://github.com/mmomtchev/ol-mbtiles/issues/68
[32]: https://github.com/mmomtchev/ol-mbtiles/issues/68
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ol-mbtiles",
"version": "2.1.0",
"version": "2.2.0",
"description": "MBTiles format reader for Openlayers",
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down

0 comments on commit 8cdd966

Please sign in to comment.