On Dec 14, 2005, at 7:28 PM, icylamb wrote:

The main question is that I also found vpath and param are similar to
args and kw. Can anyone explain to me what the differences between
them? When and where should we use these pairs accordingly?

There's no difference in the functionality, it's just a usage convention that most of the time you will see 'args' and 'kw'.

All that something like "def default(self, *args, **kw)" does is to assign positional arguments to 'args' and keyword arguments to 'kw' within the scope of the function or method being defined.

It really doesn't matter what you call them. You could just as easily do something like "def default(self, *my_arguments, **my_keywords)" and then access their values with 'my_arguments' and 'my_keywords'.

See http://python.org/doc/current/ref/function.html

--Tracy

Reply via email to