MAP::OpenStreetMapSource Class Reference

#include <MAP/OpenStreetMapSource.h>

Inheritance diagram for MAP::OpenStreetMapSource:

MAP::MapSource MAUtil::DownloadListener List of all members.

Public Member Functions

 OpenStreetMapSource ()
virtual ~OpenStreetMapSource ()
MapSourceKind getSourceKind () const
MAExtent getTileSize () const
int getMagnificationMin () const
int getMagnificationMax () const
void getTileUrl (char *buffer, MapTileCoordinate tileXY)
MapTileCoordinate lonLatToTile (LonLat lonlat, int magnification)
PixelCoordinate lonLatToPixel (LonLat lonlat, int magnification)
LonLat tileCenterToLonLat (const int tileSize, const MapTileCoordinate &tile, const double offsetX, const double offsetY)
void requestTile (const MapTileCoordinate tileXY, IMapSourceListener *listener, MapSourceClientData *clientData)
void clearQueue ()
void finishedDownloading (Downloader *downloader, MAHandle data)
void downloadCancelled (Downloader *downloader)
void error (Downloader *downloader, int code)
virtual void notifyProgress (Downloader *downloader, int downloadedBytes, int totalBytes)
virtual bool outOfMemory (Downloader *downloader)

Constructor & Destructor Documentation

MAP::OpenStreetMapSource::OpenStreetMapSource  ) 
 

virtual MAP::OpenStreetMapSource::~OpenStreetMapSource  )  [virtual]
 


Member Function Documentation

MapSourceKind MAP::OpenStreetMapSource::getSourceKind  )  const [inline, virtual]
 

Returns source kind

Implements MAP::MapSource.

MAExtent MAP::OpenStreetMapSource::getTileSize  )  const [inline, virtual]
 

Returns tile size

Implements MAP::MapSource.

int MAP::OpenStreetMapSource::getMagnificationMin  )  const [inline, virtual]
 

Returns minimum magnification

Implements MAP::MapSource.

int MAP::OpenStreetMapSource::getMagnificationMax  )  const [inline, virtual]
 

Returns maximum magnification

Implements MAP::MapSource.

void MAP::OpenStreetMapSource::getTileUrl char *  buffer,
MapTileCoordinate  tileXY
[virtual]
 

Returns URL for retrieving a tile

Implements MAP::MapSource.

MapTileCoordinate MAP::OpenStreetMapSource::lonLatToTile LonLat  lonlat,
int  magnification
[virtual]
 

Converts LonLat to tile coordinates for a tile that contains the lonlat point.

Implements MAP::MapSource.

PixelCoordinate MAP::OpenStreetMapSource::lonLatToPixel LonLat  lonlat,
int  magnification
[virtual]
 

Converts LonLat to a pixel coordinate, in a global pixel grid

Implements MAP::MapSource.

LonLat MAP::OpenStreetMapSource::tileCenterToLonLat const int  tileSize,
const MapTileCoordinate tile,
const double  offsetX,
const double  offsetY
[virtual]
 

Convert tile center plus pixel offset to WGS84 lat/lon.

Implements MAP::MapSource.

void MAP::MapSource::requestTile const MapTileCoordinate  tileXY,
IMapSourceListener listener,
MapSourceClientData clientData
[inherited]
 

Returns all tiles required to cover specified rectangle around centerpoint.

void MAP::MapSource::clearQueue  )  [inherited]
 

Clears any queued requests

void MAP::MapSource::finishedDownloading Downloader downloader,
MAHandle  data
[virtual, inherited]
 

Called when all data has been downloaded.

Parameters:
downloader A pointer to the downloader sending this event.
data MAHandle to the binary data resource with the downloaded data.

Implements MAUtil::DownloadListener.

void MAP::MapSource::downloadCancelled Downloader downloader  )  [virtual, inherited]
 

Called if the download has been cancelled.

Parameters:
downloader A pointer to the downloader sending this event.

Implements MAUtil::DownloadListener.

void MAP::MapSource::error Downloader downloader,
int  code
[virtual, inherited]
 

Called if an error occured.

Parameters:
downloader A pointer to the downloader sending this event.
code The error code describing the error. See CONNERR .

Implements MAUtil::DownloadListener.

virtual void MAUtil::DownloadListener::notifyProgress Downloader downloader,
int  downloadedBytes,
int  totalBytes
[virtual, inherited]
 

Called when some data has been downloaded to notify about the progress of the download.

Parameters:
downloader A pointer to the downloader sending this event.
downloadedBytes The amount of bytes downloaded.
totalBytes The amount of bytes to be downloaded.

virtual bool MAUtil::DownloadListener::outOfMemory Downloader downloader  )  [virtual, inherited]
 

Called if the Downloader runs out of memory. Try to free some resource memory. If you managed to free some, return true to make the Downloader try again. If you can't free any more, return false to make the Downloader fail with CONNERR_DOWNLOADER_OOM. The default implementation does nothing and returns false.


Generated on Sat Feb 13 00:15:38 2010 for MoSync 2 beta 1 by  doxygen 1.4.6-NO