Resolve some name conflict in auto-gen'd Java code.
HIDL can now use ArrayList, HwBlob etc. as type names.
Bug: 31527497
Test: mma
Change-Id: I76c62d14d4f19a73bbc1de76e88e5be6a7df5542
diff --git a/VectorType.cpp b/VectorType.cpp
index 5b6caf1..a804b5f 100644
--- a/VectorType.cpp
+++ b/VectorType.cpp
@@ -73,7 +73,7 @@
elementJavaType = mElementType->getJavaWrapperType();
}
- return "ArrayList<"
+ return "java.util.ArrayList<"
+ elementJavaType
+ ">";
}
@@ -451,7 +451,7 @@
out << "{\n";
out.indent();
- out << "HwBlob _hidl_blob = ";
+ out << "android.os.HwBlob _hidl_blob = ";
if (isReader) {
out << parcelObj
@@ -460,7 +460,7 @@
size_t align, size;
getAlignmentAndSize(&align, &size);
- out << "new HwBlob("
+ out << "new android.os.HwBlob("
<< size
<< " /* size */);\n";
}
@@ -539,7 +539,7 @@
out << "{\n";
out.indent();
- out << "HwBlob childBlob = "
+ out << "android.os.HwBlob childBlob = "
<< parcelName
<< ".readEmbeddedBuffer(\n";
@@ -622,7 +622,7 @@
elementType->getAlignmentAndSize(&elementAlign, &elementSize);
// XXX make HwBlob constructor take a long instead of an int?
- out << "HwBlob childBlob = new HwBlob((int)(_hidl_vec_size * "
+ out << "android.os.HwBlob childBlob = new android.os.HwBlob((int)(_hidl_vec_size * "
<< elementSize
<< "));\n";