|
| 1 | + |
| 2 | +# TileLayer |
| 3 | + |
| 4 | +DantSu\OpenStreetMapStaticAPI\TileLayer define tile server url and related configuration |
| 5 | + |
| 6 | + |
| 7 | + |
| 8 | +* Full name: `\DantSu\OpenStreetMapStaticAPI\TileLayer` |
| 9 | + |
| 10 | +**See Also:** |
| 11 | + |
| 12 | +* https://github.com/DantSu/php-osm-static-api - Github page of this project |
| 13 | + |
| 14 | + |
| 15 | + |
| 16 | +## Methods |
| 17 | + |
| 18 | +- *(static)* [defaultTileLayer](#defaulttilelayer) |
| 19 | +- [__construct](#-__construct) |
| 20 | +- [setOpacity](#-setopacity) |
| 21 | +- [getTileUrl](#-gettileurl) |
| 22 | +- [getAttributionText](#-getattributiontext) |
| 23 | +- [getTile](#-gettile) |
| 24 | + |
| 25 | +### ::defaultTileLayer |
| 26 | + |
| 27 | +Default tile server. OpenStreetMaps with related attribution text |
| 28 | + |
| 29 | + |
| 30 | + |
| 31 | +* This method is **static**. |
| 32 | + |
| 33 | + |
| 34 | + |
| 35 | + |
| 36 | + |
| 37 | +#### Return Value: |
| 38 | + |
| 39 | + **\DantSu\OpenStreetMapStaticAPI\TileLayer** : default tile server |
| 40 | + |
| 41 | + |
| 42 | + |
| 43 | +--- |
| 44 | +### ->__construct |
| 45 | + |
| 46 | +TileLayer constructor |
| 47 | + |
| 48 | + |
| 49 | + |
| 50 | + |
| 51 | + |
| 52 | + |
| 53 | + |
| 54 | + |
| 55 | +#### Parameters: |
| 56 | + |
| 57 | +| Parameter | Type | Description | |
| 58 | +|-----------|------|-------------| |
| 59 | +| `url` | **string** | tile server url with placeholders (`x`, `y`, `z`, `r`, `s`) | |
| 60 | +| `attributionText` | **string** | tile server attribution text | |
| 61 | +| `subdomains` | **string** | tile server subdomains | |
| 62 | + |
| 63 | + |
| 64 | + |
| 65 | + |
| 66 | +--- |
| 67 | +### ->setOpacity |
| 68 | + |
| 69 | +Set opacity of the layer |
| 70 | + |
| 71 | + |
| 72 | + |
| 73 | + |
| 74 | + |
| 75 | + |
| 76 | + |
| 77 | + |
| 78 | +#### Parameters: |
| 79 | + |
| 80 | +| Parameter | Type | Description | |
| 81 | +|-----------|------|-------------| |
| 82 | +| `opacity` | **float** | Opacity value (0 to 1) | |
| 83 | + |
| 84 | + |
| 85 | +#### Return Value: |
| 86 | + |
| 87 | + **$this** : Fluent interface |
| 88 | + |
| 89 | + |
| 90 | + |
| 91 | +--- |
| 92 | +### ->getTileUrl |
| 93 | + |
| 94 | +Get tile url for coordinates and zoom level |
| 95 | + |
| 96 | + |
| 97 | + |
| 98 | + |
| 99 | + |
| 100 | + |
| 101 | + |
| 102 | + |
| 103 | +#### Parameters: |
| 104 | + |
| 105 | +| Parameter | Type | Description | |
| 106 | +|-----------|------|-------------| |
| 107 | +| `x` | **int** | x coordinate | |
| 108 | +| `y` | **int** | y coordinate | |
| 109 | +| `z` | **int** | zoom level | |
| 110 | + |
| 111 | + |
| 112 | +#### Return Value: |
| 113 | + |
| 114 | + **string** : tile url |
| 115 | + |
| 116 | + |
| 117 | + |
| 118 | +--- |
| 119 | +### ->getAttributionText |
| 120 | + |
| 121 | +Get attribution text |
| 122 | + |
| 123 | + |
| 124 | + |
| 125 | + |
| 126 | + |
| 127 | + |
| 128 | + |
| 129 | + |
| 130 | + |
| 131 | +#### Return Value: |
| 132 | + |
| 133 | + **string** : Attribution text |
| 134 | + |
| 135 | + |
| 136 | + |
| 137 | +--- |
| 138 | +### ->getTile |
| 139 | + |
| 140 | +Get an image tile |
| 141 | + |
| 142 | + |
| 143 | + |
| 144 | + |
| 145 | + |
| 146 | + |
| 147 | + |
| 148 | + |
| 149 | +#### Parameters: |
| 150 | + |
| 151 | +| Parameter | Type | Description | |
| 152 | +|-----------|------|-------------| |
| 153 | +| `x` | **float** | | |
| 154 | +| `y` | **float** | | |
| 155 | +| `z` | **int** | | |
| 156 | + |
| 157 | + |
| 158 | +#### Return Value: |
| 159 | + |
| 160 | + **\DantSu\PHPImageEditor\Image** : Image instance containing the tile |
| 161 | + |
| 162 | + |
| 163 | + |
| 164 | +--- |
| 165 | + |
| 166 | + |
| 167 | +--- |
| 168 | +> Automatically generated from source code comments on 2022-05-31 using [phpDocumentor](http://www.phpdoc.org/) |
0 commit comments