1. 单行String
单引号是普通字符串, 双引号是GString
def hw = 'hello, world'
println 'hello, world'
println 'groovy say "Hello, world!"'
println "groovy say ${hw}" 2. 多行String
def blogAddr = 'http://www.blogjava.net/waterye'
println """\
Water Ye's blog:
${blogAddr}
"""
3. 使用range获取substring
println hw[hw.length()-1..0] 不用羡慕python,ruby了
4. 增加的api, 参考gdk
http://groovy.codehaus.org/groovy-jdk.html