Skip to content

Instantly share code, notes, and snippets.

@miceno
Created December 30, 2010 20:34
Show Gist options
  • Save miceno/760267 to your computer and use it in GitHub Desktop.
Save miceno/760267 to your computer and use it in GitHub Desktop.
var_dump in Groovy
// ReflectionToStringBuilder wraps a class and outputs a string describing
// its attributes, more or less similar to var_dump in PHP
import org.apache.commons.lang.builder.ReflectionToStringBuilder
variable= new ComplexObject()
println new ReflectionToStringBuilder( variable).toString()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment