Skip to content

Instantly share code, notes, and snippets.

@amontalenti
Last active January 2, 2016 15:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save amontalenti/8322307 to your computer and use it in GitHub Desktop.
Save amontalenti/8322307 to your computer and use it in GitHub Desktop.
Groovy example of lightweight data modelling
package org.pixelmonkey.groovytests;
someItems = [1, 2, 3, 4]
someItems.each {
println it
}
someMapping = ["ST": "started", "IP": "in progress", "DN": "done"]
someMapping.each { key, val ->
println "${key} => ${val}"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment