|
| FileMapDataProvider (const std::string &paths="", int maxConcurrentRequests=10) |
|
void | setSearchPath (const std::string &pathString) |
| Set search paths, separated by semicolon.
|
|
void | setIndexPath (const std::string &indexPath) |
| Set index file path. This should be a writeable directory where we can store index files for the input data sets. This is used for better performance during startup if you have many input data files.
|
|
bool | initialize (int maxRecursionLevels=4) |
| Initialize file provider, scanning through all directories recursively and storing file information/bounding rectangles.
|
|
MapEntry | addMapDataset (const std::string &mapSignature, const std::string &name, Maria::MapContentType contentType, ValueBag ¶ms, const std::vector< std::string > &files) |
| Manually add a data set from files.
|
|
bool | GetMapEntry (const MapContentQuery &mapQuery, MapEntry &mapEntry, unsigned long timeout=0) override |
|
std::shared_ptr< MariaProtobuf::FetchMapReplyMessage > | GetTileData (const GenerateMapTileRequest &req, unsigned long timeout_ms=0) override |
|
void | GetMapEntries (std::vector< MapEntry > &mapEntries) const override |
|
int | GetMaxConcurrentRequests () const |
|
bool | AddRequest (const MapContentQuery &request, FullTileId tileId, std::shared_ptr< ITileDataResponseTarget > responseTarget) override |
| Add request to provider. Returns false if provider queue is full.
|
|
FullTileId | RemoveRequest (int tileCacheId, bool removeNewest=false) override |
| Try to remove request from queue associated with a specific tile cache.
|
|
int | PendingRequestCount (int tileCacheId=-1) const override |
| Count of pending requests for specified tile cache.
|
|
virtual int | GetFlags () |
|
virtual bool | GetMapEntry (const MapContentQuery &mapQuery, Maria::MapEntry &mapEntry, unsigned long timeout=0)=0 |
|
virtual std::shared_ptr< MariaProtobuf::FetchMapReplyMessage > | GetTileData (const GenerateMapTileRequest &req, unsigned long timeout_ms=0)=0 |
|
virtual void | GetMapEntries (std::vector< MapEntry > &mapEntries) const =0 |
|
virtual bool | AddRequest (const MapContentQuery &request, FullTileId tileId, std::shared_ptr< ITileDataResponseTarget > responseTarget)=0 |
| Add request to provider. Returns false if provider queue is full.
|
|
virtual FullTileId | RemoveRequest (int tileCacheId, bool removeNewest=false)=0 |
| Try to remove request from queue associated with a specific tile cache.
|
|
virtual int | PendingRequestCount (int tileCacheId=-1) const =0 |
| Count of pending requests for specified tile cache.
|
|
virtual void | GetMapEntries (std::vector< MapEntry > &mapEntries) const =0 |
| Get all map entries served by the provider. Note that if "*" is set as map signature, the provider can provide data for map signatures of given map type.
|
|
FileMapDataProvider - File based map data provider This data provider will read rastermapconfigs from disk, resolve map queries and return map tiles.
bool Maria::FileMapDataProvider::GetMapEntry |
( |
const MapContentQuery & |
mapQuery, |
|
|
MapEntry & |
mapEntry, |
|
|
unsigned long |
timeout = 0 |
|
) |
| |
|
overridevirtual |
Get a map catalog entry from a map query. This method should fill out the provided mapEntry
with the resolved data for the given mapQuery
.
The method should return true on success, and false on failure.
The method should block until a response can be given, but at most timeout
ms. If timeout
= 0, it may block indefinitely.
Implements Maria::IMapDataProvider.