Created
June 8, 2011 13:18
-
-
Save mresetar/1014399 to your computer and use it in GitHub Desktop.
Groovy ToJsonSucks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import groovy.json.JsonOutput | |
class User { | |
def ime | |
def prezime | |
} | |
def u = new User(ime:'Ime', prezime:'Prezime') | |
use (JsonOutput) { | |
println u.toJson() | |
println u.ime.toJson() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment