cartopy.io.shapereader.BasicReader#

class cartopy.io.shapereader.BasicReader(filename, bbox=None)[source]#

Provide an interface for accessing the contents of a shapefile.

The primary methods used on a BasicReader instance are records() and geometries().

geometries()[source]#

Return an iterator of shapely geometries from the shapefile.

This interface is useful for accessing the geometries of the shapefile where knowledge of the associated metadata is not necessary. In the case where further metadata is needed use the records() interface instead, extracting the geometry from the record with the geometry() method.

records()[source]#

Return an iterator of Record instances.