我可以写批注在Groovy? [英] Can I write annotation in Groovy?

查看:202
本文介绍了我可以写批注在Groovy?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道我可以标注在Groovy与批注我的课,但我可以写在Groovy注解本身(而不是仅仅使用Java编写的注释)?如果是这样,从什么版本?

I know I can annotate my classes in Groovy with annotations, but can I write the annotation itself in Groovy (as opposed to just using annotation written in Java)? If so, from what version?

推荐答案

定义在Groovy注解尚未编译器所支持。一直以来,有一个共同的编译器是不是一个大问题,但肯定不会采取一些常规岬从常规远: - )

Defining of annotations in groovy is not yet supported by the compiler. Since, there is a joint compiler it is not a big problem but sure does take some groovy-ness away from groovy :-)

查看更多:
  http://docs.groovy-lang.org/latest/html/documentation/ #_annotation

询问时,它会在这里的支持:
user@groovy.$c$chaus.org

Ask when it will be supported here: user@groovy.codehaus.org

这篇关于我可以写批注在Groovy?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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