您将什么称为“回调”?或“关闭”一般来说?
当我们为它们做笔记时,我们应该使用哪个关键字/标签来描述它们。
如果将它们放在“软件设计”类别下是否合适?
@edit:更多的是关于如何对事物进行分类。当你在学习的时候,会出现一些术语,那么你会把它归入你自己的本体中的哪一类呢?
Which keyword / tag should we use to describe them when we're taking notes for them.
If they are placed under the category "software design", is it appropriate?
@edit: It's more about how you category things. When you are in learning, some terminology appears, so what category will you assign it in your own ontology?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
是的,我怀疑我会在这里暴露我的愚蠢,但无论如何:
希望定义它们能够帮助您对它们进行分类 - 我不认为术语“callback”和“closure”实际上意味着同一件事,尽管根据上下文它们可以指同一件事。
我已经将这个答案制作成社区维基,所以请随意编辑它,直到它正确为止。
回调
http://en.wikipedia.org/wiki/Callback_(computer_science)< /a>
<块引用>
回调是作为参数传递给其他代码的可执行代码
“什么是回调功能?” (堆栈溢出)
关闭
http://en.wikipedia.org /wiki/Closure_(计算机科学)
<块引用>
术语“闭包”经常被错误地用来表示匿名函数。这可能是因为大多数实现匿名函数的语言允许它们形成闭包,并且程序员通常同时引入这两个概念。然而,这些是不同的概念
Right, I suspect I’m going to reveal my stupidity here, but anyway:
Hopefully defining them will help you classify them — I don’t think the terms “callback” and “closure” actually mean the same thing, although they can both refer to the same thing depending on context.
I’ve made this answer community wiki, so please feel free to edit it until it’s correct.
callback
http://en.wikipedia.org/wiki/Callback_(computer_science)
“What is a callback function?” (Stack Overflow)
closure
http://en.wikipedia.org/wiki/Closure_(computer_science)
我认为函数指针可以用作“回调”或“闭包”的标签。
I think Function Pointer can be used as tag for "callback" or "closures".
我认为“闭包”和“回调”相关,但没有等同的地方。我想说两者之间的最低共同点是“高阶函数”,它发生在“函数式编程”中。
http://en.wikipedia.org/wiki/Higher_order_functions
http://en.wikipedia.org/wiki/Functional_programming
I consider "Closures" and "Callbacks" related but nowhere equivalent. The lowest common denominator between the two I would say are "Higher-Order Functions", which take place in "Functional Programming".
http://en.wikipedia.org/wiki/Higher_order_functions
http://en.wikipedia.org/wiki/Functional_programming