summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Steven Moreland <smoreland@google.com> 2019-10-16 22:05:12 -0700
committer android-build-merger <android-build-merger@google.com> 2019-10-16 22:05:12 -0700
commit1a60cdd28a3593b02e7114632f4bae816338184e (patch)
tree291194f823adbaeacb6099e73920f9e1a2c4732a
parent1be177675be93f4e25e60d90633c80d651634282 (diff)
parent87a62c74712069211a7122c9db15c775fc2fa620 (diff)
Merge "libbinder_ndk: more AStatus auto utils" am: 7f8013feef
am: 87a62c7471 Change-Id: I0781002ab7a14f3c56f079670e2b1f3295aa812a
-rw-r--r--libs/binder/ndk/include_ndk/android/binder_auto_utils.h17
1 files changed, 16 insertions, 1 deletions
diff --git a/libs/binder/ndk/include_ndk/android/binder_auto_utils.h b/libs/binder/ndk/include_ndk/android/binder_auto_utils.h
index c6868b07ef..dc3c8d2e3a 100644
--- a/libs/binder/ndk/include_ndk/android/binder_auto_utils.h
+++ b/libs/binder/ndk/include_ndk/android/binder_auto_utils.h
@@ -201,7 +201,22 @@ class ScopedAStatus : public impl::ScopedAResource<AStatus*, void, AStatus_delet
/**
* See AStatus_isOk.
*/
- bool isOk() { return get() != nullptr && AStatus_isOk(get()); }
+ bool isOk() const { return get() != nullptr && AStatus_isOk(get()); }
+
+ /**
+ * See AStatus_getExceptionCode
+ */
+ binder_exception_t getExceptionCode() const { return AStatus_getExceptionCode(get()); }
+
+ /**
+ * See AStatus_getServiceSpecificError
+ */
+ int32_t getServiceSpecificError() const { return AStatus_getServiceSpecificError(get()); }
+
+ /**
+ * See AStatus_getStatus
+ */
+ binder_status_t getStatus() const { return AStatus_getStatus(get()); }
/**
* Convenience method for okay status.