def funtion1(){
//Code here
}
方法 2:
def function2={
//code here
}
实际上什么限定这两个类型的方法之间的差异......哪一个是好..
def funtion1(){
//Code here
}
方法 2:
def function2={
//code here
}
实际上什么限定这两个类型的方法之间的差异......哪一个是好..
作为方法的控制器操作 现在可以将控制器操作定义为方法,而不像以前的Grails版本那样使用闭包。
In fact this is now the preferred way of expressing an action。
所以,如果你使用grails> 2. *,定义动作为方法而不是作为衣服。
类似的问题:
嘿,请你接受我的答案,如果它是正确的吗? – havenchyk