Have Metadata use android::CameraMetadata.

Ownership is much more clear than with the various double
raw metadata pointers.

BUG: 30140438
TEST: unit tests pass

Change-Id: Ib0de3bb4b9e6dc30594230e46f40ffaea06df51d
diff --git a/modules/camera/3_4/metadata/metadata.h b/modules/camera/3_4/metadata/metadata.h
index d25a040..36e238b 100644
--- a/modules/camera/3_4/metadata/metadata.h
+++ b/modules/camera/3_4/metadata/metadata.h
@@ -17,6 +17,7 @@
 #ifndef V4L2_CAMERA_HAL_METADATA_H_
 #define V4L2_CAMERA_HAL_METADATA_H_
 
+#include <camera/CameraMetadata.h>
 #include <hardware/camera3.h>
 
 #include "../common.h"
@@ -28,10 +29,10 @@
   Metadata();
   virtual ~Metadata();
 
-  int FillStaticMetadata(camera_metadata_t** metadata);
-  bool IsValidRequest(const camera_metadata_t* metadata);
-  int SetRequestSettings(const camera_metadata_t* metadata);
-  int FillResultMetadata(camera_metadata_t** metadata);
+  int FillStaticMetadata(android::CameraMetadata* metadata);
+  bool IsValidRequest(const android::CameraMetadata& metadata);
+  int SetRequestSettings(const android::CameraMetadata& metadata);
+  int FillResultMetadata(android::CameraMetadata* metadata);
 
  protected:
   // Helper for the child constructors to fill in metadata components.