我们定义的函数是在计算时间数据时进行调用的,所以我们也可以在报表的初始化阶段声明它们(见于图 10)。
The functions we defined are called when calculating the time data, so we also have to declare them in the initialization phase of the report (see Figure 10).
不幸的是,它将导致图5所示的错误消息,因为在dojo . forEach方法调用中声明的函数创建了一个闭包,该闭包将this定义为引用它本身。
Unfortunately, it will result in the error message shown in Figure 5, because the function declared in the dojo.forEach method call creates a closure that defines this as referring to its own body.
图9:function List View显示了应用程序调用的函数,以及它们使用的内存量。
Figure 9: the function List View shows the functions being called by an application and the amount of memory they use.
- Well, just a moment ago, we did have -- -- and this time I'll use some chalk here -- a moment ago, we did have a picture depicting what was going on when you call the function.
好的,刚才,我们确实有-,这一次我将用一些粉笔-,刚才,我们有一张图描绘了当我们调用函数的时候,会发生什么事情。
应用推荐