QGIS API Documentation  2.5.0-Master
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Member Functions | Static Public Member Functions | List of all members
QgsCoordinateTransformCache Class Reference

Cache coordinate transform by authid of source/dest transformation to avoid the overhead of initialisation for each redraw. More...

#include <qgscrscache.h>

Public Member Functions

 ~QgsCoordinateTransformCache ()
 
const QgsCoordinateTransformtransform (const QString &srcAuthId, const QString &destAuthId, int srcDatumTransform=-1, int destDatumTransform=-1)
 Returns coordinate transformation. More...
 
void invalidateCrs (const QString &crsAuthId)
 Removes transformations where a changed crs is involved from the cache. More...
 

Static Public Member Functions

static
QgsCoordinateTransformCache
instance ()
 

Detailed Description

Cache coordinate transform by authid of source/dest transformation to avoid the overhead of initialisation for each redraw.

Constructor & Destructor Documentation

QgsCoordinateTransformCache::~QgsCoordinateTransformCache ( )

Member Function Documentation

QgsCoordinateTransformCache * QgsCoordinateTransformCache::instance ( )
static
void QgsCoordinateTransformCache::invalidateCrs ( const QString &  crsAuthId)

Removes transformations where a changed crs is involved from the cache.

const QgsCoordinateTransform * QgsCoordinateTransformCache::transform ( const QString &  srcAuthId,
const QString &  destAuthId,
int  srcDatumTransform = -1,
int  destDatumTransform = -1 
)

Returns coordinate transformation.

Cache keeps ownership

Parameters
srcAuthIdauth id string of source crs
destAuthIdauth id string of dest crs
srcDatumTransformid of source's datum transform
destDatumTransformid of destinations's datum transform

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