Migrate NNAPI runtime to canonical types

This change replaces most uses of HAL types in the codebase with
equivalent canonical types. Later changes will introduce more
refactorings.

Also removes unused files nn/runtime/test/Bridge.{h,cpp}.

Bug: 160669906
Fix: 155923931
Test: NeuralNetworksTest_static (all 7 passes)
Test: NeuralNetworksTest_operations
Test: NeuralNetworksTest_utils
Test: NeuralNetworksTest_logtag
Test: nnCache_test
Test: BlobCache_test
Change-Id: I63fa286e926a096948f1b1b172d1d562c4f52f29
Merged-In: I63fa286e926a096948f1b1b172d1d562c4f52f29
(cherry picked from commit daa4b515bc15a2ac7755f0666c023d7e3caa951a)
diff --git a/common/operations/LSTM.cpp b/common/operations/LSTM.cpp
index 3051cfd..e64d0c4 100644
--- a/common/operations/LSTM.cpp
+++ b/common/operations/LSTM.cpp
@@ -22,18 +22,16 @@
 
 #include "CpuExecutor.h"
 #include "CpuOperationUtils.h"
-#include "HalInterfaces.h"
 #include "OperationsUtils.h"
 #include "Tracing.h"
 #include "Utils.h"
+#include "nnapi/Types.h"
 
 namespace android {
 namespace nn {
 
 namespace {
 
-using namespace hal;
-
 template <typename T>
 inline T* GetBuffer(RunTimeOperandInfo* operand) {
     return reinterpret_cast<T*>(operand->buffer);
@@ -113,7 +111,7 @@
     } else {
         // For LSTM from HAL v1.0 assign operands with no values
         static RunTimeOperandInfo no_value;
-        no_value.lifetime = OperandLifeTime::NO_VALUE;
+        no_value.lifetime = Operand::LifeTime::NO_VALUE;
 
         input_layer_norm_weights_ = &no_value;
         forget_layer_norm_weights_ = &no_value;
@@ -221,8 +219,8 @@
     // omitted ones can be omited in case CIFG LSTM is used.
     params->use_layer_norm = !IsNullInput(output_layer_norm_weights);
 
-    params->use_projection_weight = (projection_weights->lifetime != OperandLifeTime::NO_VALUE);
-    params->use_projection_bias = (projection_bias->lifetime != OperandLifeTime::NO_VALUE);
+    params->use_projection_weight = (projection_weights->lifetime != Operand::LifeTime::NO_VALUE);
+    params->use_projection_bias = (projection_bias->lifetime != Operand::LifeTime::NO_VALUE);
 
     // Make sure the input gate bias is present only when not a CIFG-LSTM.
     if (params->use_cifg) {