[Gdal-dev] PHP-OGR Extension- OGR_DS_GetLayer() doesn't always return the same
layer handle
Normand Savard
nsavard at dmsolutions.ca
Thu May 15 14:05:52 EDT 2003
Hi Frank,
I have built php unit tests to verify the php-ogr extension functions.
In order to perform data comparison against validation data, I need to
get some specific layers. I used "OGR_DS_GetLayer()" function to get an
handle to a specific layer. As you know, this function takes two
arguments: a data source handle and a layer number.
I was believing that giving the same layer number, this function will
always return me the same layer handle. But when I copied a data
directory to a new directory the order of the layers changed. So, when
I call the "OGR_DS_GetLayer()" function with a specific layer number,
the return layer handle did not correspond to the layer into the source
directory.
As a workaround, I used "OGR_DS_GetLayerByName()" function. Is there a
plan to modify the "OGR_DS_GetLayer()" function to always return the
same layer handle giving a specific layer number?
Norm
More information about the Gdal-dev
mailing list