Signals | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
tile_map::TileSource Class Referenceabstract

#include <tile_source.h>

Inheritance diagram for tile_map::TileSource:
Inheritance graph
[legend]

Signals

void ErrorMessage (const std::string &error_msg) const
 
void InfoMessage (const std::string &info_msg) const
 

Public Member Functions

virtual size_t GenerateTileHash (int32_t level, int64_t x, int64_t y)=0
 
virtual QString GenerateTileUrl (int32_t level, int64_t x, int64_t y)=0
 
virtual const QString & GetBaseUrl () const
 
virtual int32_t GetMaxZoom () const
 
virtual int32_t GetMinZoom () const
 
virtual const QString & GetName () const
 
virtual QString GetType () const =0
 
virtual bool IsCustom () const
 
virtual void SetBaseUrl (const QString &base_url)
 
virtual void SetCustom (bool is_custom)
 
virtual void SetMaxZoom (int32_t max_zoom)
 
virtual void SetMinZoom (int32_t min_zoom)
 
virtual void SetName (const QString &name)
 
virtual ~TileSource ()
 

Protected Member Functions

 TileSource ()
 

Protected Attributes

QString base_url_
 
bool is_custom_
 
int32_t max_zoom_
 
int32_t min_zoom_
 
QString name_
 

Detailed Description

Represents a network source for map tiles; contains information about how to connect to the source and how to retrieve tiles from it.

Implementations of this should be specific to a type of map server such as WMS, WMTS, or TMS, and implement the appropriate methods for retrieiving tiles from those servers.

Definition at line 47 of file tile_source.h.

Constructor & Destructor Documentation

virtual tile_map::TileSource::~TileSource ( )
inlinevirtual

Definition at line 51 of file tile_source.h.

tile_map::TileSource::TileSource ( )
inlineprotected

Definition at line 104 of file tile_source.h.

Member Function Documentation

void tile_map::TileSource::ErrorMessage ( const std::string &  error_msg) const
signal
virtual size_t tile_map::TileSource::GenerateTileHash ( int32_t  level,
int64_t  x,
int64_t  y 
)
pure virtual

Generates a hash that uniquely identifies the tile from this source at the specified level and coordinates.

Parameters
levelThe zoom level
xThe X coordinate
yThe Y coordinate
Returns
A hash identifying the tile

Implemented in tile_map::BingSource, and tile_map::WmtsSource.

virtual QString tile_map::TileSource::GenerateTileUrl ( int32_t  level,
int64_t  x,
int64_t  y 
)
pure virtual

Generates an HTTP or HTTPS URL that refers to a map tile from this source at the given level and x and y coordinates.

Parameters
levelThe zoom level
xThe x coordinate
yThe y coordinate
Returns
A URL referring to the map tile

Implemented in tile_map::BingSource, and tile_map::WmtsSource.

const QString & tile_map::TileSource::GetBaseUrl ( ) const
virtual

Definition at line 35 of file tile_source.cpp.

int32_t tile_map::TileSource::GetMaxZoom ( ) const
virtual

Definition at line 55 of file tile_source.cpp.

int32_t tile_map::TileSource::GetMinZoom ( ) const
virtual

Definition at line 65 of file tile_source.cpp.

const QString & tile_map::TileSource::GetName ( ) const
virtual

Definition at line 75 of file tile_source.cpp.

virtual QString tile_map::TileSource::GetType ( ) const
pure virtual

Returns a string identifying the type of map source ("wmts", "bing", etc.)

Returns

Implemented in tile_map::BingSource, and tile_map::WmtsSource.

void tile_map::TileSource::InfoMessage ( const std::string &  info_msg) const
signal
bool tile_map::TileSource::IsCustom ( ) const
virtual

Definition at line 45 of file tile_source.cpp.

void tile_map::TileSource::SetBaseUrl ( const QString &  base_url)
virtual

Definition at line 40 of file tile_source.cpp.

void tile_map::TileSource::SetCustom ( bool  is_custom)
virtual

Definition at line 50 of file tile_source.cpp.

void tile_map::TileSource::SetMaxZoom ( int32_t  max_zoom)
virtual

Definition at line 60 of file tile_source.cpp.

void tile_map::TileSource::SetMinZoom ( int32_t  min_zoom)
virtual

Definition at line 70 of file tile_source.cpp.

void tile_map::TileSource::SetName ( const QString &  name)
virtual

Definition at line 80 of file tile_source.cpp.

Member Data Documentation

QString tile_map::TileSource::base_url_
protected

Definition at line 104 of file tile_source.h.

bool tile_map::TileSource::is_custom_
protected

Definition at line 107 of file tile_source.h.

int32_t tile_map::TileSource::max_zoom_
protected

Definition at line 108 of file tile_source.h.

int32_t tile_map::TileSource::min_zoom_
protected

Definition at line 109 of file tile_source.h.

QString tile_map::TileSource::name_
protected

Definition at line 110 of file tile_source.h.


The documentation for this class was generated from the following files:


tile_map
Author(s): Marc Alban
autogenerated on Thu Jun 6 2019 19:25:35