与
inspectPython
3没有特别的区别,但总体上看这里
语言中删除了“未绑定方法”的概念。现在将方法作为类属性引用时,您将获得一个普通的函数对象。
我对跨平台的建议是:
getmembers(X, predicate=lambda x: isfunction(x) or ismethod(x))

与
inspectPython
语言中删除了“未绑定方法”的概念。现在将方法作为类属性引用时,您将获得一个普通的函数对象。
我对跨平台的建议是:
getmembers(X, predicate=lambda x: isfunction(x) or ismethod(x))