Merge pull request #245 from ganeshs/master

Added import mappings for java.util.Set and java.sql.Timestamp
This commit is contained in:
Tony Tam 2014-08-20 23:43:05 -07:00
commit a13f46e781
2 changed files with 4 additions and 0 deletions

View File

@ -84,9 +84,11 @@ class BasicJavaGenerator extends BasicGenerator {
override def importMapping = Map(
"File" -> "java.io.File",
"Date" -> "java.util.Date",
"Timestamp" -> "java.sql.Timestamp",
"Array" -> "java.util.*",
"ArrayList" -> "java.util.*",
"List" -> "java.util.*",
"Set" -> "java.util.*",
"DateTime" -> "org.joda.time.*",
"LocalDateTime" -> "org.joda.time.*",
"LocalDate" -> "org.joda.time.*",

View File

@ -123,6 +123,8 @@ class BasicJavaGeneratorTest extends FlatSpec with ShouldMatchers {
it should "honor the import mapping" in {
config.importMapping("Date") should be ("java.util.Date")
config.importMapping("DateTime") should be ("org.joda.time.*")
config.importMapping("Timestamp") should be ("java.sql.Timestamp")
config.importMapping("Set") should be ("java.util.*")
}
/*