Skip to content

Commit

Permalink
Merge pull request #23 from chinkong83/mywork
Browse files Browse the repository at this point in the history
change optional to true for Array type case
  • Loading branch information
joejoe321321 authored Mar 13, 2017
2 parents ddd7121 + 35cbf37 commit 2340f46
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions utils/java-util.go
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ func JavaType(reg rdl.TypeRegistry, rdlType rdl.TypeRef, optional bool, items rd
i = items
}
}
gitems := JavaType(reg, i, false, "", "")
gitems := JavaType(reg, i, true, "", "")
//return gitems + "[]" //if arrays, not lists
return "List<" + gitems + ">"
case rdl.BaseTypeMap:
Expand All @@ -392,8 +392,8 @@ func JavaType(reg rdl.TypeRegistry, rdlType rdl.TypeRef, optional bool, items rd
i = items
}
}
gkeys := JavaType(reg, k, false, "", "")
gitems := JavaType(reg, i, false, "", "")
gkeys := JavaType(reg, k, true, "", "")
gitems := JavaType(reg, i, true, "", "")
return "Map<" + gkeys + "," + gitems + ">"
case rdl.BaseTypeStruct:
switch t.Variant {
Expand Down

0 comments on commit 2340f46

Please sign in to comment.