Python return self

在Python中,return self的作用为:
Returning self from a method simply means that your method returns a reference to the instance object on which it was called. This can sometimes be seen in use with object oriented APIs that are designed as a fluent interface that encourages method cascading.

链式调用

posted @ 2020-10-07 23:08  捷后愚生  阅读(235)  评论(0编辑  收藏  举报