Added knowledge of namespacing into generation.

This is the first step in making code aware of namespacing. Currently,
the solution to generate symbols which are properly namespaced is to
post-process text after it is being outputed by a Formatter. Ideally
objects will know what namespace they are in and be able to print
themselves out accordingly. This change specifically will allow
generated code to remove namespaces from symbols that don't need
to be qualified entirely without relying on post-processing to remove
the namespace.

Change-Id: Ie535d05a64eb3d6c7d3b5451abdaa289c574170f
diff --git a/VectorType.cpp b/VectorType.cpp
index 1019424..910bc39 100644
--- a/VectorType.cpp
+++ b/VectorType.cpp
@@ -26,10 +26,17 @@
     : mElementType(elementType) {
 }
 
-std::string VectorType::getCppType(StorageMode mode, std::string *extra) const {
+void VectorType::addNamedTypesToSet(std::set<const FQName> &set) const {
+    mElementType->addNamedTypesToSet(set);
+}
+
+std::string VectorType::getCppType(StorageMode mode,
+                                   std::string *extra,
+                                   bool specifyNamespaces) const {
     const std::string base =
-        "::android::hardware::hidl_vec<"
-        + mElementType->getCppType(extra)
+          std::string(specifyNamespaces ? "::android::hardware::" : "")
+        + "hidl_vec<"
+        + mElementType->getCppType(extra, specifyNamespaces)
         + ">";
 
     CHECK(extra->empty());