You might be surprised here if you are unfamiliar with the trick — Python does not have an "official" staticscoping declaration.
这里,如果您不熟悉这个诀窍,可能会感到诧异—python没有“正式”的静态范围声明。
2
Notice too that the Listing 2 version could consist entirely of static methods. No Shared knowledge exists between the methods, so I have less need for encapsulation via scoping.