Hi,
I'm looking for a way to output (build) json.
For example, I see there is a way to build xml
http://www.scala-lang.org/intro/xml.html
object XMLTest2 extends Application {
import scala.xml._
val df = java.text.DateFormat.getDateInstance()
val dateString = df.format(new java.util.Date())
def theDate(name: String) =
<dateMsg addressedTo={ name }>
Hello, { name }! Today is { dateString }
</dateMsg>;
println(theDate("John Doe").toString())
}
Is there a way to output JSON rather than xml?
Something similar to what I"m looking for is found in groovy
http://www.jroller.com/aalmiray/entry/building_json_with_groovy
Thanks,
Josh