In general, I think it would be helpful if methods that modify an object
instance would return a reference to the modified instance instead of
'None'. This would allow calls to be chained if desired rather than
having to assign an explicit named reference whenever more than one
operation is desired.
For example, I think it would be great if in addition to writing this:
myclass = mb.class_('myclass')
...
myclass_foo = myclass.member_function('goo')
myclass_foo.rename('foo')
myclass_foo.include()
... you could also write this:
myclass = mb.class_('myclass')
...
myclass.member_function('goo').rename('foo').include()
Thanks,
--- Kevin
|