[Gdal-dev] RFC 12: Improved File Management

Frank Warmerdam warmerdam at pobox.com
Mon May 7 13:47:45 EDT 2007


Ari Jolma wrote:
> Frank Warmerdam kirjoitti:
>>
>> I normally think of OGRLayer's as being analygous to bands
> 
> Hmm, I've been using OGROpen with a directory name instead of filename. 
> Then I've been able to loop through all vector data layers (for example 
> shapefiles) in that directory. I've sometimes wondered what happens if 
> there are for example shapefiles _and_ mapinfo files in the same directory.

Ari,

I see what you mean.  This is a convenience offered by some OGR drivers.

If a directory contains a mixture of shapefiles and mapinfo files any
attempt to open the directory will give you a shapefile datasource and
the mapinfo files will be ignored.

It's important to keep in mind that this "open a directory" support
is a feature of a driver, not OGR in general.  Only a couple drivers
support this and it isn't always done in an equivelent approach.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | President OSGeo, http://osgeo.org




More information about the Gdal-dev mailing list