什么是“间接级别”?大卫·惠勒的格言是什么意思? [英] What does "level of indirection" mean in David Wheeler's aphorism?

查看:121
本文介绍了什么是“间接级别”?大卫·惠勒的格言是什么意思?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在书中读过这句话:

I've read this quote in a book:


在计算机科学中,没有其他问题无法解决间接级别。

There is no problem in computer science that can't be solved using another level of indirection.

有人可以解释吗? 间接级别是什么意思?

Can someone explain that? What does "level of indirection" mean?

据我所知,间接寻址是一种奇特的名称,用于使用值的指针而不是值本身。请为我澄清这一点。

From what I understood, indirection is a fancy name for using a pointer of a value instead of the value itself. Please clarify this for me.

推荐答案

间接使用的是从广义上讲会使用其他东西的东西。

"Indirection" is using something that uses something else, in its broadest sense.

因此,您的示例使用一个值的指针而不是该值的指针,使此定义适合一个层次。指针是东西,值是其他东西。

So your example, using a pointer of a value instead of the value, fits this definition at one level. The pointer is the something and the value is the something else.

通常,范围更大:


  • 使用网站以图形方式显示基于XML的服务生成的数据。这里是网站,而背后隐藏的是数据。

  • 使用操作系统访问显示屏。这是至少间接的两层。操作系统使用屏幕驱动程序。一个东西用别的东西。然后,屏幕驱动程序直接与屏幕硬件对话,从而使其在此处和此处发出微小的光点。驱动程序是使用其他东西(硬件)的下一个东西。

  • 一个API在较高级别上处理某些事情并且该API在同一层上处理相同的事情并不少见。较低的水平。再次在低级API之上添加了一个间接级别,我们将其称为经过改进的新API。

最后一个示例

在我们处理某些事物时,我们掌握了它,并学习了如何将其抽象到更高的抽象水平,因此需要新的间接级别,我们可以通过将一些工作卸载到新的API来更快地解决更大的问题。

As we work with something we master it and learn how to abstract it to a higher level of abstraction, thus a new level of indirection is needed and we can solve bigger problems faster by offloading some of the work to the new API.

这篇关于什么是“间接级别”?大卫·惠勒的格言是什么意思?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆