MCPcopy Create free account
hub / github.com/ImageEngine/cortex / bindCompoundObject

Function bindCompoundObject

src/IECorePython/CompoundObjectBinding.cpp:287–316  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

285}
286
287void bindCompoundObject()
288{
289
290 RunTimeTypedClass<CompoundObject>()
291 .def( init<>() )
292 .def("__init__", make_constructor(&copyConstructor), "Copy constructor.")
293 .def( "__repr__", &repr )
294 .def( "__len__", &len )
295 .def( "__getitem__", &getItem )
296 .def( "__setitem__", &setItem )
297 .def( "__delitem__", &delItem )
298 .def( "__contains__", &contains )
299 .def( "has_key", &contains )
300 .def( "keys", &keys )
301 .def( "values", &values )
302 .def( "items", &items )
303 .def( "update", &update )
304 .def( "get", &get, "m.get(k [, v])\nReturns m[k] if found; otherwise, returns v.",
305 (
306 boost::python::arg( "self" ),
307 boost::python::arg( "key" ),
308 boost::python::arg( "defaultValue" ) = object()
309 )
310 )
311 .def( "defaultInstance", &defaultInstance ).staticmethod( "defaultInstance" )
312 ;
313
314 CompoundObjectFromPythonDict();
315
316}
317
318} // namespace IECorePython

Callers 1

BOOST_PYTHON_MODULEFunction · 0.85

Calls 1

Tested by

no test coverage detected