Ordinary methods, static methods, class methods

Method #: 
# common method: to save in the class, is called by the object, self -----> caller Object
# static methods: by the class directly call
# class methods: direct call by the class, cls ----> the current class
# applicable scene:
# If the objects need to save some values, perform a function, the value of the object in use ------> common method
# value object does not require any -----> static method

Guess you like

Origin www.cnblogs.com/startl/p/11875860.html