Skip to content

Commit a71132d

Browse files
author
Caitlin Bales (MSFT)
committed
Fully-qualify java.util.List to prevent naming collisions
1 parent 359bc2d commit a71132d

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

Templates/Android/BaseModel.template.tt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@
359359
public string ParamType(OdcmParameter c) {
360360
var typeString = c.Type.GetTypeString();
361361
if (c.IsCollection){
362-
typeString = String.Format("List<{0}>", c.Type.GetTypeString());
362+
typeString = String.Format("java.util.List<{0}>", c.Type.GetTypeString());
363363
} else if (typeString.Equals("Stream")) {
364364

365365
// Excel introduced the use of "Edm.Stream" types
@@ -515,8 +515,7 @@ import {0}.generated.*;
515515
import {0}.options.*;
516516
import {0}.serializer.*;
517517

518-
import java.util.Arrays;
519-
import java.util.List;";
518+
import java.util.Arrays;";
520519
return string.Format(format,
521520
host.CurrentModel.NamespaceName(),
522521
host.TemplateInfo.OutputParentDirectory);
@@ -643,7 +642,7 @@ public {1} {2}{3}{4} {{";
643642
{
644643
if (!property.IsNavigation())
645644
{
646-
propertyType = "List<" + property.GetTypeString() + ">";
645+
propertyType = "java.util.List<" + property.GetTypeString() + ">";
647646
}
648647
else
649648
{

0 commit comments

Comments
 (0)