Generate interfaces to JSON (for use in Scala impl)
testcase for enum in type args