OgcApiTilesLayer Class
A layer that displays map images from OGC API Tiles servers.
NuGet/Assembly: Carmenta.Engine.5.17.0.nupkg (in the CEOgc assembly)
Syntax
public class OgcApiTilesLayer : HttpLayer
Remarks
There is a map configuration sample ogc_api_tiles_map.px that demonstrates how a OgcApiTilesLayer can be used to read raster maps from an OGC API Tiles server.
There is a Getting started with OGC API Tiles article that can be used in parallel with this reference manual.
An OgcApiTilesLayer generates its presentation using tiled map images from OGC API Tiles services. The layer can connect to servers that supports the OGC API Tiles (map tiles) interface, such as Carmenta Tile Engine. See https://ogcapi.ogc.org/tiles for more information about the OGC API Tiles standard.
To use an OgcApiTilesLayer you usually only need to set the Url property to a link to an OGC API collection, to identify the service. Everything else will be configured automatically when the layer is being initialized.
The layer will, when initialized, access the standardized links from the specified OGC API service to discover relevant information such as which tilesets that are available and identify the specific endpoints to request tiles from.
Once an OgcApiTilesLayer has been initialized it will contain only a single OgcApiTilesServerLayer that corresponds to an OGC API collection hosted on the server. You can access the OgcApiTilesServerLayer instance through the Layers property.
The layer list itself is read-only and any attempt to insert or remove layers from it will result in an exception being thrown. You can however use it to enable/disable child layers, apply named styles, populate a GUI control and more. Please see OgcApiTilesServerLayer for more information.
OgcApiTilesLayer and TileLayer
OgcApiTilesLayer manages its own asynchronous I/O requests and image caching. Hence it does not require a TileLayer.
TileLayer is aware of this fact and if it finds an OgcApiTilesLayer as a child, it "leaves it alone" to handle its own updates. So you can still safely put your OgcApiTilesLayers layers under a tile layer if you wish.
Inheritance Hierarchy
System.Object
EngineObject
Layer
LayerSet
HttpLayer
OgcApiTilesLayer
Platforms
Windows, Linux, Android
OgcApiTilesLayer Members
The OgcApiTilesLayer type has the following members.
Constructors
Name | Description |
---|---|
OgcApiTilesLayer | Creates a new instance of the OgcApiTilesLayer class. |
Properties
Name | Description |
---|---|
Asynchronous | Gets or sets a flag indicating if the layer should work in synchronous or asynchronous mode. |
BlendMode | Gets or sets the blend mode that determines how the layer is combined with previously rendered layers. Inherited from Layer |
CachePath | Gets or sets a directory on disk where tiles are cached. |
CacheSize | Gets or sets the maximum amount of disk space used by the disk cache. |
Condition | Gets or sets the Condition that determines whether the OgcApiTilesLayer is drawn or not. Inherited from Layer |
Description | Gets or sets a short description of the layer. Inherited from Layer |
DisableOnError | Gets or sets a value specifying if an error within the layer should automatically disable the layer, or throw an exception. Inherited from Layer |
DisplayName | Gets or sets a display name for the layer. Inherited from Layer |
Effects | List of effects Inherited from Layer |
Enabled | Determines whether the OgcApiTilesLayer is enabled or not. Inherited from Layer |
EnabledDuringQuickUpdates | Determines whether the OgcApiTilesLayer is temporarily turned off during mouse interactions. Inherited from Layer |
ExplicitStyle | Gets the named style for the layer in the map image |
Format | Gets or sets the graphics format of the map image generated by the OGC API service. |
IsDisposed | Gets a value that tells whether the current OgcApiTilesLayer has been disposed. Inherited from EngineObject |
IsoMetadataDocument | Gets or sets the path or URL to an ISO 19139 metadata document for the layer. Inherited from Layer |
Layers | Gets the child layers of this OgcApiTilesLayer. Inherited from LayerSet |
Legend | Gets or sets a map legend associated with this layer. Inherited from Layer |
MaxScale | Gets or sets the highest inverted nominal scale in a 2D view, or the furthest distance in a 3D globe view, at which objects from this OgcApiTilesLayer should be drawn. Inherited from Layer |
MinScale | Gets or sets the lowest inverted nominal scale this OgcApiTilesLayer should be drawn at. Inherited from Layer |
Name | Gets or sets the name of the layer. Inherited from Layer |
NamedStyles | Gets the list of named styles that can be enabled for the layer. Inherited from Layer |
NativeHandle | Gets the native Carmenta Engine kernel object the current OgcApiTilesLayer represents. Inherited from EngineObject |
Opacity | Gets or sets a value that specifies the opacity of the layer. Inherited from Layer |
Password | Gets or sets the password used for basic authentication by the OGC WMS/WMTS/API service. Inherited from HttpLayer |
ThrowExceptions | Gets or sets a flag indicating if exceptions should be thrown when an error occurs. Inherited from HttpLayer |
Timeout | Gets or sets a value that indicates how long the layer will wait for a response from the OGC WMS/WMTS/API server. Inherited from HttpLayer |
Url | Gets or sets the URL to a web mapping service. Inherited from HttpLayer |
User | Gets or sets the username used for basic authentication by the OGC WMS/WMTS/API service. Inherited from HttpLayer |
IUserProperties.UserProperties | Gets the AttributeSet that contains the user properties. Inherited from IUserProperties |
VendorSpecificParameters | Gets or sets any vendor specific parameters that are appended to all requests. |
Methods
Name | Description |
---|---|
Clone | Creates a copy of an object. Inherited from EngineObject |
Dispose | Releases the reference to the native Carmenta Engine kernel instance the EngineObject represents. Inherited from EngineObject |
EnableStyle | Enables or disables a named style for the layer. Inherited from Layer |
Equals | Determines whether this instance is equal to another. Inherited from EngineObject |
FindChildObject | Overloaded. Finds the child object with the specified name. Inherited from Layer |
FlushCache | Marks the layer as flushed which will release cached resources during the next update. Inherited from Layer |
FlushDiskCache | Removes all tiles cached on disk. |
GetChildObjects | Overloaded. Gets the child objects of the current object. Inherited from Layer |
GetDataBounds | Calculates the bounds of all dataset coverages in the layer. Inherited from Layer |
GetFeatureAttributes | Gets information about all attributes that may be present on features in this layer. Inherited from Layer |
GetFeatures | Overloaded. Gets features from the layer and any child layers. Inherited from Layer |
GetLastError | Gets the error message for the last error that occurred within the layer. Inherited from Layer |
GetLocalizedDescription | Gets a localized version of the layer description in a specific language. Inherited from Layer |
GetLocalizedDisplayName | Gets a localized version of the layer display name in a specific language. Inherited from Layer |
GetLocalizedIsoMetadataDocument | Gets the path to an ISO 19139 metadata document for a specific language. Inherited from Layer |
HasLocalizedDescription | Checks if a localized version of the layer description is available in a specific language. Inherited from Layer |
HasLocalizedDisplayName | Checks if a localized version of the layer display name is available in a specific language. Inherited from Layer |
HasLocalizedIsoMetadataDocument | Checks if an ISO 19139 metadata document is available for a specific language. Inherited from Layer |
Initialize | Initializes the OgcApiTilesLayer instance. |
IsStyleEnabled | Checks if a certain style is enabled for the layer or not. Inherited from Layer |
MoveLayer | Moves a child layer to a new position. Inherited from LayerSet |
Reset | Resets the OgcWmtsLayer, OgcWmsLayer or OgcApiTilesLayer instance to its default state. Inherited from HttpLayer |
SetLocalizedDescription | Sets a layer description in a specific language. Inherited from Layer |
SetLocalizedDisplayName | Sets a layer display name in a specific language. Inherited from Layer |
SetLocalizedIsoMetadataDocument | Sets the path to an ISO 19139 metadata document for the layer, for a specific language. Inherited from Layer |
Events
Name | Description |
---|---|
EnabledChanged | Occurs when the value of the Enabled property has changed. Inherited from Layer |
ServiceChanged | Occurs when the layer has detected changes to the OGC service. Inherited from HttpLayer |