[英]With vs Identify Block in Groovy
我想知道是否有人可以通过一些简单的例子向我解释Groovy中with {}和identify {}块之间的区别。
Actually, there isn't one, they do the same thing. 实际上,没有人会做同样的事情。 From the Groovy docs :
从Groovy文档 :
identity
Allows the closure to be called for the object reference self.
Synonym for 'with()'.
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.