我们希望通过多重分派(multiple dispatch ),能够为一个函数所有可能的参数选出最有效的执行方法。这些参数可能有着不同的定义,来自不同的数据类型,却能提供相同的功能...
基于34个网页-相关网页
以上来源于: WordNet
Another prior Charming Python column developed and presented a library to enable multiple dispatch.
可爱的Python先前的另一期文章开发并描述了一个支持多分派的库。
This concept will be familiar to readers who have used Lisp's CLOS or who have read my discussion of multiple dispatch using Python (Resources).
对于使用过Lisp的CLOS或者读过我对使用Python进行多种分派的讨论(参考资料)的读者,这个概念应该是熟悉的。
Standard Python does not let you configure this type of multiple dispatch; but fortunately, you can do so using the module multimethods that I have written.
标准Python不允许配置这种类型的多分派;但幸运的是,您可以使用我所编写的模块multimethods来做到这一点。
应用推荐