- is an agile and dynamic language for the Java Virtual Machine
- builds upon the strengths of Java but has additional power features inspired by languages like Python, Ruby and Smalltalk
- makes modern programming features available to Java developers with almost-zero learning curve
- supports Domain-Specific Languages and other compact syntax so your code becomes easy to read and maintain
- makes writing shell and build scripts easy with its powerful processing primitives, OO abilities and an Ant DSL
- increases developer productivity by reducing scaffolding code when developing web, GUI, database or console applications
- simplifies testing by supporting unit testing and mocking out-of-the-box
- seamlessly integrates with all existing Java objects and libraries
- compiles straight to Java bytecode so you can use it anywhere you can use Java
- Java Specification Request 241 (JSR 241)
Groovy是在Runtime时解析,可以用来定制化,比如把定制化信息保存在MDS中,让不同的用户使用不同的业务规则。
Oracle ADF 提供了以下声明式的方式使用Groovy:
(1) 设置EO或VO的Attribute值
(2) 定义在EO的Attribute上的验证规则
(3) 错误消息
(4) 定义在VO上的绑定变量
(5) 定义在VO上的Transient Attribute的验证
参考文献:
1. http://groovy.codehaus.org/
2. http://www.ibm.com/developerworks/cn/java/j-pg/
3. http://www.ibm.com/developerworks/cn/java/j-pg02179.html
没有评论:
发表评论