这些闭包名称反映了它们的含义。
用闭包进行定制会有一些惊人之处。
Customization with closures can take you in some surprising places.
可以使用匿名的内部类来实现闭包。
Primarily, you can use anonymous inner classes to implement closures.
这种闭包也可以包含间接关联路径。
闭包是函数语言的共有特征之一。
Closures are one of the common features of functional languages.
可以用闭包来表述模型架构上的完整性。
You can use closures to make statements about the architectural integrity of your models.
清单2:不含闭包的循环。
一流的方法和函数(闭包)
现在我们来研究闭包的一些更刺激的方面。
他的最终建议也是只在真正必要时使用闭包。
His final recommendations are also along the lines of only using closures when truly necessary.
闭包是具有闭合作用域的匿名函数。
您可以根据需要通过闭包构建自己的抽象概念。
You can build in your own abstractions as needed, with closures.
让我们在此基础上了解如何在php中使用闭包。
清单8是清单7的一个简化版,其中使用了闭包。
Listing 8 shows a simplification of Listing 7, using a closure.
我们可以通过将闭包定义为静态闭包禁用此行为。
We can disable this behavior by defining the closure to be static.
但是,这些现有的闭包返回的值是html格式的。
这些仅仅是众多使用闭包进行迭代的方法中的两种。
These are just two more of the many ways that you can use closures to iterate.
这个示例中所使用的生成递归闭包的方法有些冗长。
The way of making recursive closures used in this example is a bit tedious.
这样,新创建域类时它们就有适当的字段和事件闭包。
That way every new domain class created already has the fields and event closures in place.
闭包的语法发生了变化,但是大多数变化只与参数有关。
The syntax for closures has changed, but mostly only with regard to parameters.
在本例中,闭包的生命周期实际上比定义闭包的方法长。
In this case, the closure's lifetime will actually be longer than the method that has defined them.
如果到现在您还没猜出来,那么可以用闭包实现同的效果。
If you haven't guessed it by now, closures can be used to achieve the same effect.
您需要寻找强mdd相关的文件组(考虑数学上的闭包)。
You want to look for groups of strongly MDD-related files (think mathematical closure).
表示闭包,其中方法的主体就是花括号中的内容。
闭包是一个会对它内部引用的所有变量进行隐式绑定的函数。
A closure is a function that carries an implicit binding to all the variables referenced within it.
如果碰巧该闭包函数跟某个事件绑定,那么就必须要解绑定。
If you happened to attach the closure to an event, then you would have to detach it from that event.
闭包可以很好地与面向对象的代码以及面向过程的代码整合。
Closures can integrate just as well with object-oriented code, as well as with procedural code.
当把这个闭包应用于实际参数3时,返回值是36。
Upon applying this to the actual parameter 3, the value 36 is returned.
在类中定义的闭包基本上与在对象外部定义的闭包相同。
Closures defined within a class are fundamentally the same as those defined outside an object.
使用复合,两个或多个简单的闭包可以组合起来构成一个更复杂的闭包。
Using composition, two or more simple closures can be combined to produce a more elaborate one.
应用推荐