Support vts generation for fmq type in hidl-gen.
* Also did a few cleanup for Templated type.
Bug: 34385794
Test: make hidl-gen
Change-Id: I539bf8fe5a1bb65c36f6041417b34ddaf99840d7
diff --git a/VectorType.cpp b/VectorType.cpp
index a58ea2c..b6267c6 100644
--- a/VectorType.cpp
+++ b/VectorType.cpp
@@ -125,6 +125,10 @@
return "TYPE_VECTOR";
}
+std::string VectorType::getVtsValueName() const {
+ return "vector_value";
+}
+
void VectorType::emitReaderWriter(
Formatter &out,
const std::string &name,
@@ -712,31 +716,6 @@
return !isVectorOfBinders();
}
-status_t VectorType::emitVtsTypeDeclarations(Formatter &out) const {
- out << "type: " << getVtsType() << "\n";
- out << "vector_value: {\n";
- out.indent();
- status_t err = mElementType->emitVtsTypeDeclarations(out);
- if (err != OK) {
- return err;
- }
- out.unindent();
- out << "}\n";
- return OK;
-}
-
-status_t VectorType::emitVtsAttributeType(Formatter &out) const {
- out << "type: TYPE_VECTOR\n" << "vector_value: {\n";
- out.indent();
- status_t status = mElementType->emitVtsAttributeType(out);
- if (status != OK) {
- return status;
- }
- out.unindent();
- out << "}\n";
- return OK;
-}
-
bool VectorType::isJavaCompatible() const {
if (!mElementType->isJavaCompatible()) {
return false;