Skip to content

Commit dcfedaa

Browse files
author
timlinux
committed
remove get prefix for crs accessor
git-svn-id: http://svn.osgeo.org/qgis/trunk@9501 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 4a91668 commit dcfedaa

20 files changed

+23
-23
lines changed

python/core/qgsdataprovider.sip

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ class QgsDataProvider : QObject
2020
* If the provider isn't capable of returning
2121
* its projection an empty srs will be return, ti will return 0
2222
*/
23-
virtual QgsCoordinateReferenceSystem getCRS() = 0;
23+
virtual QgsCoordinateReferenceSystem crs() = 0;
2424

2525

2626
/**

src/core/qgsdataprovider.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ class CORE_EXPORT QgsDataProvider : public QObject
6060
* If the provider isn't capable of returning
6161
* its projection an empty srs will be return, ti will return 0
6262
*/
63-
virtual QgsCoordinateReferenceSystem getCRS() = 0;
63+
virtual QgsCoordinateReferenceSystem crs() = 0;
6464

6565

6666
/**

src/core/qgsvectorlayer.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -3435,7 +3435,7 @@ void QgsVectorLayer::setCoordinateSystem()
34353435
//
34363436

34373437
// get CRS directly from provider
3438-
*mCRS = mDataProvider->getCRS();
3438+
*mCRS = mDataProvider->crs();
34393439

34403440
//QgsCoordinateReferenceSystem provides a mechanism for FORCE a srs to be valid
34413441
//which is inolves falling back to system, project or user selected

src/providers/delimitedtext/qgsdelimitedtextprovider.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,7 @@ int QgsDelimitedTextProvider::capabilities() const
510510
}
511511

512512

513-
QgsCoordinateReferenceSystem QgsDelimitedTextProvider::getCRS()
513+
QgsCoordinateReferenceSystem QgsDelimitedTextProvider::crs()
514514
{
515515
// TODO: make provider projection-aware
516516
return QgsCoordinateReferenceSystem(); // return default CRS

src/providers/delimitedtext/qgsdelimitedtextprovider.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ class QgsDelimitedTextProvider : public QgsVectorDataProvider
152152
*/
153153
bool isValid();
154154

155-
virtual QgsCoordinateReferenceSystem getCRS();
155+
virtual QgsCoordinateReferenceSystem crs();
156156

157157
/* new functions */
158158

src/providers/gpx/qgsgpxprovider.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -843,7 +843,7 @@ QString QgsGPXProvider::description() const
843843
return GPX_DESCRIPTION;
844844
} // QgsGPXProvider::description()
845845

846-
QgsCoordinateReferenceSystem QgsGPXProvider::getCRS()
846+
QgsCoordinateReferenceSystem QgsGPXProvider::crs()
847847
{
848848
return QgsCoordinateReferenceSystem(); // use default CRS - it's WGS84
849849
}

src/providers/gpx/qgsgpxprovider.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ class QgsGPXProvider : public QgsVectorDataProvider
139139
/** return description */
140140
virtual QString description() const;
141141

142-
virtual QgsCoordinateReferenceSystem getCRS();
142+
virtual QgsCoordinateReferenceSystem crs();
143143

144144

145145
/* new functions */

src/providers/grass/qgsgrassprovider.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -1267,7 +1267,7 @@ struct Map_info *QgsGrassProvider::layerMap( int layerId )
12671267
}
12681268

12691269

1270-
QgsCoordinateReferenceSystem QgsGrassProvider::getCRS()
1270+
QgsCoordinateReferenceSystem QgsGrassProvider::crs()
12711271
{
12721272
QString Wkt;
12731273

src/providers/grass/qgsgrassprovider.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ class GRASS_EXPORT QgsGrassProvider : public QgsVectorDataProvider
195195
*/
196196
bool isValid();
197197

198-
QgsCoordinateReferenceSystem getCRS();
198+
QgsCoordinateReferenceSystem crs();
199199

200200
// ----------------------------------- Edit ----------------------------------
201201

src/providers/memory/memoryprovider.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ bool QgsMemoryProvider::isValid()
218218
return ( mWkbType != QGis::WKBUnknown );
219219
}
220220

221-
QgsCoordinateReferenceSystem QgsMemoryProvider::getCRS()
221+
QgsCoordinateReferenceSystem QgsMemoryProvider::crs()
222222
{
223223
// TODO: make provider projection-aware
224224
return QgsCoordinateReferenceSystem(); // return default CRS

src/providers/memory/memoryprovider.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ class QgsMemoryProvider : public QgsVectorDataProvider
175175
*/
176176
bool isValid();
177177

178-
virtual QgsCoordinateReferenceSystem getCRS();
178+
virtual QgsCoordinateReferenceSystem crs();
179179

180180
protected:
181181

src/providers/ogr/qgsogrprovider.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -1230,7 +1230,7 @@ QGISEXTERN bool createEmptyDataSource( const QString& uri,
12301230
return true;
12311231
}
12321232

1233-
QgsCoordinateReferenceSystem QgsOgrProvider::getCRS()
1233+
QgsCoordinateReferenceSystem QgsOgrProvider::crs()
12341234
{
12351235
QgsDebugMsg( "entering." );
12361236

src/providers/ogr/qgsogrprovider.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class QgsOgrProvider : public QgsVectorDataProvider
4545

4646

4747

48-
virtual QgsCoordinateReferenceSystem getCRS();
48+
virtual QgsCoordinateReferenceSystem crs();
4949

5050

5151
/**

src/providers/postgres/qgspostgresprovider.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -2711,7 +2711,7 @@ void QgsPostgresProvider::showMessageBox( const QString& title,
27112711
}
27122712

27132713

2714-
QgsCoordinateReferenceSystem QgsPostgresProvider::getCRS()
2714+
QgsCoordinateReferenceSystem QgsPostgresProvider::crs()
27152715
{
27162716
QgsCoordinateReferenceSystem srs;
27172717
srs.createFromSrid( srid.toInt() );

src/providers/postgres/qgspostgresprovider.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ class QgsPostgresProvider : public QgsVectorDataProvider
7373
* If the provider isn't capable of returning
7474
* its projection an empty srs will be return, ti will return 0
7575
*/
76-
virtual QgsCoordinateReferenceSystem getCRS();
76+
virtual QgsCoordinateReferenceSystem crs();
7777

7878
/** Select features based on a bounding rectangle. Features can be retrieved with calls to nextFeature.
7979
* @param fetchAttributes list of attributes which should be fetched

src/providers/wfs/qgswfsprovider.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ void QgsWFSProvider::begin()
135135
mFeatureIterator = mSelectedFeatures.begin();
136136
}
137137

138-
QgsCoordinateReferenceSystem QgsWFSProvider::getCRS()
138+
QgsCoordinateReferenceSystem QgsWFSProvider::crs()
139139
{
140140
return mSourceCRS;
141141
}

src/providers/wfs/qgswfsprovider.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ class QgsWFSProvider: public QgsVectorDataProvider
7171
const QgsFieldMap & fields() const;
7272
void begin();
7373

74-
virtual QgsCoordinateReferenceSystem getCRS();
74+
virtual QgsCoordinateReferenceSystem crs();
7575

7676
/* Inherited from QgsDataProvider */
7777

src/providers/wms/qgswmsprovider.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -2194,7 +2194,7 @@ QString QgsWmsProvider::identifyAsText( const QgsPoint& point )
21942194
}
21952195

21962196

2197-
QgsCoordinateReferenceSystem QgsWmsProvider::getCRS()
2197+
QgsCoordinateReferenceSystem QgsWmsProvider::crs()
21982198
{
21992199
// TODO: implement
22002200
return QgsCoordinateReferenceSystem();

src/providers/wms/qgswmsprovider.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,7 @@ class QgsWmsProvider : public QgsRasterDataProvider
374374
* If the provider isn't capable of returning
375375
* its projection an empty srs will be return, ti will return 0
376376
*/
377-
virtual QgsCoordinateReferenceSystem getCRS();
377+
virtual QgsCoordinateReferenceSystem crs();
378378

379379
/**
380380
* Add the list of WMS layer names to be rendered by this server

tests/algorithms/projections/projectioncshandlingtest.h

+4-4
Original file line numberDiff line numberDiff line change
@@ -266,12 +266,12 @@ class ProjectionCsHandlingTest : public CppUnit::TestCase
266266
CPPUNIT_ASSERT( myInputSpatialRefSys.importFromWkt( &pWkt ) == OGRERR_NONE );
267267
std::cout << "\tGetting proj4 paramters with morph to ESRI form" << std::endl;
268268
CPPUNIT_ASSERT( myInputSpatialRefSys.morphFromESRI() == OGRERR_NONE );
269-
OGRSpatialReference oTargetCRS;
269+
OGRSpatialReference oTarcrs;
270270
char *pWgs84 = ( char * )wkt.ascii();
271-
oTargetCRS.importFromWkt( &pWgs84 );
271+
oTarcrs.importFromWkt( &pWgs84 );
272272
OGRCoordinateTransformation *poCT;
273273
poCT = OGRCreateCoordinateTransformation( &myInputSpatialRefSys,
274-
&oTargetCRS );
274+
&oTarcrs );
275275
double x = 0.0;
276276
double y = 0.0;
277277
poCT->Transform( 1, &x, &y );
@@ -283,7 +283,7 @@ class ProjectionCsHandlingTest : public CppUnit::TestCase
283283
std::cout << "\tPROJ4: " << proj4src << std::endl;
284284

285285
std::cout << "Testing inverse transform" << std::endl;
286-
poCT = OGRCreateCoordinateTransformation( &oTargetCRS, &myInputSpatialRefSys );
286+
poCT = OGRCreateCoordinateTransformation( &oTarcrs, &myInputSpatialRefSys );
287287
x = -154.0;
288288
y = 50.0;
289289
poCT->Transform( 1, &x, &y );

0 commit comments

Comments
 (0)