small correction:

1. Layer method takes named arguments
2. CreateLayer expects Python dictionary
This commit is contained in:
Artem Pavlenko 2006-03-01 15:34:23 +00:00
parent 0f3fcc7f34
commit c93e9c7d5b
2 changed files with 3 additions and 3 deletions

View file

@ -50,7 +50,7 @@ class _Envelope(Envelope,_injector):
(self.minx,self.miny,self.maxx,self.maxy)
def Layer (**keywords):
return _Layer(keywords)
return CreateLayer(keywords)
#register datasources

View file

@ -83,7 +83,7 @@ namespace
{
//user-friendly wrapper that uses Python dictionary
using namespace boost::python;
_Layer create_layer(const dict& d)
Layer create_layer(const dict& d)
{
parameters params;
boost::python::list keys=d.keys();
@ -114,5 +114,5 @@ void export_layer()
(&Layer::styles,return_value_policy<reference_existing_object>()))
.def_pickle(layer_pickle_suite())
;
def("_Layer",&create_layer);
def("CreateLayer",&create_layer);
}