Merge cherrypicks of ['android-review.googlesource.com/2995229'] into 24Q2-release.
Change-Id: I4fd0f4bc2e71e0730d36ee254a1a5eadfaf86c1c
diff --git a/libs/binder/ndk/Android.bp b/libs/binder/ndk/Android.bp
index ccf3ce8..30dbddd 100644
--- a/libs/binder/ndk/Android.bp
+++ b/libs/binder/ndk/Android.bp
@@ -40,6 +40,7 @@
llndk: {
symbol_file: "libbinder_ndk.map.txt",
+ export_llndk_headers: ["libvendorsupport_llndk_headers"],
},
export_include_dirs: [
@@ -79,9 +80,11 @@
],
header_libs: [
+ "libvendorsupport_llndk_headers",
"jni_headers",
],
export_header_lib_headers: [
+ "libvendorsupport_llndk_headers",
"jni_headers",
],
diff --git a/libs/binder/ndk/include_cpp/android/persistable_bundle_aidl.h b/libs/binder/ndk/include_cpp/android/persistable_bundle_aidl.h
index 864ff50..3aacbe9 100644
--- a/libs/binder/ndk/include_cpp/android/persistable_bundle_aidl.h
+++ b/libs/binder/ndk/include_cpp/android/persistable_bundle_aidl.h
@@ -24,6 +24,13 @@
namespace aidl::android::os {
+#if defined(__ANDROID_VENDOR__)
+#define AT_LEAST_V_OR_202404 constexpr(__ANDROID_VENDOR_API__ >= 202404)
+#else
+// TODO(b/322384429) switch this to __ANDROID_API_V__ when V is finalized
+#define AT_LEAST_V_OR_202404 (__builtin_available(android __ANDROID_API_FUTURE__, *))
+#endif
+
/**
* Wrapper class that enables interop with AIDL NDK generation
* Takes ownership of the APersistableBundle* given to it in reset() and will automatically
@@ -32,7 +39,7 @@
class PersistableBundle {
public:
PersistableBundle() noexcept {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
mPBundle = APersistableBundle_new();
}
}
@@ -42,13 +49,13 @@
PersistableBundle(PersistableBundle&& other) noexcept : mPBundle(other.release()) {}
// duplicates, does not take ownership of the APersistableBundle*
PersistableBundle(const PersistableBundle& other) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
mPBundle = APersistableBundle_dup(other.mPBundle);
}
}
// duplicates, does not take ownership of the APersistableBundle*
PersistableBundle& operator=(const PersistableBundle& other) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
mPBundle = APersistableBundle_dup(other.mPBundle);
}
return *this;
@@ -58,7 +65,7 @@
binder_status_t readFromParcel(const AParcel* _Nonnull parcel) {
reset();
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return APersistableBundle_readFromParcel(parcel, &mPBundle);
} else {
return STATUS_INVALID_OPERATION;
@@ -69,7 +76,7 @@
if (!mPBundle) {
return STATUS_BAD_VALUE;
}
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return APersistableBundle_writeToParcel(mPBundle, parcel);
} else {
return STATUS_INVALID_OPERATION;
@@ -84,7 +91,7 @@
*/
void reset(APersistableBundle* _Nullable pBundle = nullptr) noexcept {
if (mPBundle) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
APersistableBundle_delete(mPBundle);
}
mPBundle = nullptr;
@@ -97,7 +104,7 @@
* what should be used to check for equality.
*/
bool deepEquals(const PersistableBundle& rhs) const {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return APersistableBundle_isEqual(get(), rhs.get());
} else {
return false;
@@ -136,7 +143,7 @@
inline std::string toString() const {
if (!mPBundle) {
return "<PersistableBundle: null>";
- } else if (__builtin_available(android __ANDROID_API_V__, *)) {
+ } else if AT_LEAST_V_OR_202404 {
std::ostringstream os;
os << "<PersistableBundle: ";
os << "size: " << std::to_string(APersistableBundle_size(mPBundle));
@@ -147,7 +154,7 @@
}
int32_t size() const {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return APersistableBundle_size(mPBundle);
} else {
return 0;
@@ -155,7 +162,7 @@
}
int32_t erase(const std::string& key) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return APersistableBundle_erase(mPBundle, key.c_str());
} else {
return 0;
@@ -163,37 +170,37 @@
}
void putBoolean(const std::string& key, bool val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
APersistableBundle_putBoolean(mPBundle, key.c_str(), val);
}
}
void putInt(const std::string& key, int32_t val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
APersistableBundle_putInt(mPBundle, key.c_str(), val);
}
}
void putLong(const std::string& key, int64_t val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
APersistableBundle_putLong(mPBundle, key.c_str(), val);
}
}
void putDouble(const std::string& key, double val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
APersistableBundle_putDouble(mPBundle, key.c_str(), val);
}
}
void putString(const std::string& key, const std::string& val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
APersistableBundle_putString(mPBundle, key.c_str(), val.c_str());
}
}
void putBooleanVector(const std::string& key, const std::vector<bool>& vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
// std::vector<bool> has no ::data().
int32_t num = vec.size();
if (num > 0) {
@@ -210,7 +217,7 @@
}
void putIntVector(const std::string& key, const std::vector<int32_t>& vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
int32_t num = vec.size();
if (num > 0) {
APersistableBundle_putIntVector(mPBundle, key.c_str(), vec.data(), num);
@@ -218,7 +225,7 @@
}
}
void putLongVector(const std::string& key, const std::vector<int64_t>& vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
int32_t num = vec.size();
if (num > 0) {
APersistableBundle_putLongVector(mPBundle, key.c_str(), vec.data(), num);
@@ -226,7 +233,7 @@
}
}
void putDoubleVector(const std::string& key, const std::vector<double>& vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
int32_t num = vec.size();
if (num > 0) {
APersistableBundle_putDoubleVector(mPBundle, key.c_str(), vec.data(), num);
@@ -234,7 +241,7 @@
}
}
void putStringVector(const std::string& key, const std::vector<std::string>& vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
int32_t num = vec.size();
if (num > 0) {
char** inVec = (char**)malloc(num * sizeof(char*));
@@ -249,13 +256,13 @@
}
}
void putPersistableBundle(const std::string& key, const PersistableBundle& pBundle) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
APersistableBundle_putPersistableBundle(mPBundle, key.c_str(), pBundle.mPBundle);
}
}
bool getBoolean(const std::string& key, bool* _Nonnull val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return APersistableBundle_getBoolean(mPBundle, key.c_str(), val);
} else {
return false;
@@ -263,7 +270,7 @@
}
bool getInt(const std::string& key, int32_t* _Nonnull val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return APersistableBundle_getInt(mPBundle, key.c_str(), val);
} else {
return false;
@@ -271,7 +278,7 @@
}
bool getLong(const std::string& key, int64_t* _Nonnull val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return APersistableBundle_getLong(mPBundle, key.c_str(), val);
} else {
return false;
@@ -279,7 +286,7 @@
}
bool getDouble(const std::string& key, double* _Nonnull val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return APersistableBundle_getDouble(mPBundle, key.c_str(), val);
} else {
return false;
@@ -291,7 +298,7 @@
}
bool getString(const std::string& key, std::string* _Nonnull val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
char* outString = nullptr;
bool ret = APersistableBundle_getString(mPBundle, key.c_str(), &outString,
&stringAllocator, nullptr);
@@ -309,7 +316,7 @@
const char* _Nonnull, T* _Nullable, int32_t),
const APersistableBundle* _Nonnull pBundle, const char* _Nonnull key,
std::vector<T>* _Nonnull vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
int32_t bytes = 0;
// call first with nullptr to get required size in bytes
bytes = getVec(pBundle, key, nullptr, 0);
@@ -331,28 +338,28 @@
}
bool getBooleanVector(const std::string& key, std::vector<bool>* _Nonnull vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getVecInternal<bool>(&APersistableBundle_getBooleanVector, mPBundle, key.c_str(),
vec);
}
return false;
}
bool getIntVector(const std::string& key, std::vector<int32_t>* _Nonnull vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getVecInternal<int32_t>(&APersistableBundle_getIntVector, mPBundle, key.c_str(),
vec);
}
return false;
}
bool getLongVector(const std::string& key, std::vector<int64_t>* _Nonnull vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getVecInternal<int64_t>(&APersistableBundle_getLongVector, mPBundle, key.c_str(),
vec);
}
return false;
}
bool getDoubleVector(const std::string& key, std::vector<double>* _Nonnull vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getVecInternal<double>(&APersistableBundle_getDoubleVector, mPBundle,
key.c_str(), vec);
}
@@ -377,7 +384,7 @@
}
bool getStringVector(const std::string& key, std::vector<std::string>* _Nonnull vec) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
int32_t bytes = APersistableBundle_getStringVector(mPBundle, key.c_str(), nullptr, 0,
&stringAllocator, nullptr);
if (bytes > 0) {
@@ -394,7 +401,7 @@
}
bool getPersistableBundle(const std::string& key, PersistableBundle* _Nonnull val) {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
APersistableBundle* bundle = nullptr;
bool ret = APersistableBundle_getPersistableBundle(mPBundle, key.c_str(), &bundle);
if (ret) {
@@ -426,77 +433,77 @@
}
std::set<std::string> getBooleanKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getBooleanKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getIntKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getIntKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getLongKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getLongKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getDoubleKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getDoubleKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getStringKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getStringKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getBooleanVectorKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getBooleanVectorKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getIntVectorKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getIntVectorKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getLongVectorKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getLongVectorKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getDoubleVectorKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getDoubleVectorKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getStringVectorKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getStringVectorKeys, mPBundle);
} else {
return {};
}
}
std::set<std::string> getPersistableBundleKeys() {
- if (__builtin_available(android __ANDROID_API_V__, *)) {
+ if AT_LEAST_V_OR_202404 {
return getKeys(&APersistableBundle_getPersistableBundleKeys, mPBundle);
} else {
return {};
diff --git a/libs/binder/ndk/include_ndk/android/persistable_bundle.h b/libs/binder/ndk/include_ndk/android/persistable_bundle.h
index 98c0cb2..1247e8e 100644
--- a/libs/binder/ndk/include_ndk/android/persistable_bundle.h
+++ b/libs/binder/ndk/include_ndk/android/persistable_bundle.h
@@ -17,6 +17,11 @@
#pragma once
#include <android/binder_parcel.h>
+#if defined(__ANDROID_VENDOR__)
+#include <android/llndk-versioning.h>
+#else
+#define __INTRODUCED_IN_LLNDK(x)
+#endif
#include <stdbool.h>
#include <stdint.h>
#include <sys/cdefs.h>
@@ -67,25 +72,26 @@
/**
* Create a new APersistableBundle.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \return Pointer to a new APersistableBundle
*/
-APersistableBundle* _Nullable APersistableBundle_new() __INTRODUCED_IN(__ANDROID_API_V__);
+APersistableBundle* _Nullable APersistableBundle_new() __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Create a new APersistableBundle based off an existing APersistableBundle.
* This is a deep copy, so the new APersistableBundle has its own values from
* copying the original underlying PersistableBundle.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle to duplicate
*
* \return Pointer to a new APersistableBundle
*/
APersistableBundle* _Nullable APersistableBundle_dup(const APersistableBundle* _Nonnull pBundle)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Delete an APersistableBundle. This must always be called when finished using
@@ -93,15 +99,15 @@
*
* \param pBundle to delete. No-op if null.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_delete(APersistableBundle* _Nullable pBundle)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Check for equality of APersistableBundles.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param lhs bundle to compare against the other param
* \param rhs bundle to compare against the other param
@@ -110,12 +116,12 @@
*/
bool APersistableBundle_isEqual(const APersistableBundle* _Nonnull lhs,
const APersistableBundle* _Nonnull rhs)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Read an APersistableBundle from an AParcel.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param parcel to read from
* \param outPBundle bundle to write to
@@ -129,12 +135,12 @@
*/
binder_status_t APersistableBundle_readFromParcel(
const AParcel* _Nonnull parcel, APersistableBundle* _Nullable* _Nonnull outPBundle)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Write an APersistableBundle to an AParcel.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle bundle to write to the parcel
* \param parcel to write to
@@ -149,25 +155,25 @@
*/
binder_status_t APersistableBundle_writeToParcel(const APersistableBundle* _Nonnull pBundle,
AParcel* _Nonnull parcel)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get the size of an APersistableBundle. This is the number of mappings in the
* object.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle to get the size of (number of mappings)
*
* \return number of mappings in the object
*/
int32_t APersistableBundle_size(const APersistableBundle* _Nonnull pBundle)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Erase any entries added with the provided key.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle to operate on
* \param key for the mapping in UTF-8 to erase
@@ -175,7 +181,7 @@
* \return number of entries erased. Either 0 or 1.
*/
int32_t APersistableBundle_erase(APersistableBundle* _Nonnull pBundle, const char* _Nonnull key)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Put a boolean associated with the provided key.
@@ -185,10 +191,11 @@
* \param key for the mapping in UTF-8
* \param value to put for the mapping
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putBoolean(APersistableBundle* _Nonnull pBundle, const char* _Nonnull key,
- bool val) __INTRODUCED_IN(__ANDROID_API_V__);
+ bool val) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Put an int32_t associated with the provided key.
@@ -198,10 +205,11 @@
* \param key for the mapping in UTF-8
* \param val value to put for the mapping
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putInt(APersistableBundle* _Nonnull pBundle, const char* _Nonnull key,
- int32_t val) __INTRODUCED_IN(__ANDROID_API_V__);
+ int32_t val) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Put an int64_t associated with the provided key.
@@ -211,10 +219,11 @@
* \param key for the mapping in UTF-8
* \param val value to put for the mapping
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putLong(APersistableBundle* _Nonnull pBundle, const char* _Nonnull key,
- int64_t val) __INTRODUCED_IN(__ANDROID_API_V__);
+ int64_t val) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Put a double associated with the provided key.
@@ -224,10 +233,11 @@
* \param key for the mapping in UTF-8
* \param val value to put for the mapping
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putDouble(APersistableBundle* _Nonnull pBundle, const char* _Nonnull key,
- double val) __INTRODUCED_IN(__ANDROID_API_V__);
+ double val) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Put a string associated with the provided key.
@@ -238,10 +248,11 @@
* \param key for the mapping in UTF-8
* \param vec vector to put for the mapping
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putString(APersistableBundle* _Nonnull pBundle, const char* _Nonnull key,
- const char* _Nonnull val) __INTRODUCED_IN(__ANDROID_API_V__);
+ const char* _Nonnull val) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Put a boolean vector associated with the provided key.
@@ -253,11 +264,12 @@
* \param vec vector to put for the mapping
* \param num number of elements in the vector
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putBooleanVector(APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, const bool* _Nonnull vec,
- int32_t num) __INTRODUCED_IN(__ANDROID_API_V__);
+ int32_t num) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Put an int32_t vector associated with the provided key.
@@ -269,11 +281,11 @@
* \param vec vector to put for the mapping
* \param num number of elements in the vector
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putIntVector(APersistableBundle* _Nonnull pBundle, const char* _Nonnull key,
const int32_t* _Nonnull vec, int32_t num)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Put an int64_t vector associated with the provided key.
@@ -285,11 +297,12 @@
* \param vec vector to put for the mapping
* \param num number of elements in the vector
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putLongVector(APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, const int64_t* _Nonnull vec,
- int32_t num) __INTRODUCED_IN(__ANDROID_API_V__);
+ int32_t num) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Put a double vector associated with the provided key.
@@ -301,11 +314,12 @@
* \param vec vector to put for the mapping
* \param num number of elements in the vector
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putDoubleVector(APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, const double* _Nonnull vec,
- int32_t num) __INTRODUCED_IN(__ANDROID_API_V__);
+ int32_t num) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Put a string vector associated with the provided key.
@@ -317,12 +331,12 @@
* \param vec vector to put for the mapping
* \param num number of elements in the vector
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putStringVector(APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key,
const char* _Nullable const* _Nullable vec, int32_t num)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Put an APersistableBundle associated with the provided key.
@@ -333,17 +347,17 @@
* \param key for the mapping in UTF-8
* \param val value to put for the mapping
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*/
void APersistableBundle_putPersistableBundle(APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key,
const APersistableBundle* _Nonnull val)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get a boolean associated with the provided key.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle to operate on
* \param key for the mapping in UTF-8
@@ -353,12 +367,12 @@
*/
bool APersistableBundle_getBoolean(const APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, bool* _Nonnull val)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get an int32_t associated with the provided key.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle to operate on
* \param key for the mapping in UTF-8
@@ -367,12 +381,13 @@
* \return true if a value exists for the provided key
*/
bool APersistableBundle_getInt(const APersistableBundle* _Nonnull pBundle, const char* _Nonnull key,
- int32_t* _Nonnull val) __INTRODUCED_IN(__ANDROID_API_V__);
+ int32_t* _Nonnull val) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Get an int64_t associated with the provided key.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle to operate on
* \param key for the mapping in UTF-8
@@ -382,12 +397,12 @@
*/
bool APersistableBundle_getLong(const APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, int64_t* _Nonnull val)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get a double associated with the provided key.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle to operate on
* \param key for the mapping in UTF-8
@@ -397,13 +412,13 @@
*/
bool APersistableBundle_getDouble(const APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, double* _Nonnull val)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get a string associated with the provided key.
* The caller is responsible for freeing the returned data.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle to operate on
* \param key for the mapping in UTF-8
@@ -418,7 +433,8 @@
int32_t APersistableBundle_getString(const APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, char* _Nullable* _Nonnull val,
APersistableBundle_stringAllocator stringAllocator,
- void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__);
+ void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Get a boolean vector associated with the provided key and place it in the
@@ -445,7 +461,7 @@
int32_t APersistableBundle_getBooleanVector(const APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, bool* _Nullable buffer,
int32_t bufferSizeBytes)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get an int32_t vector associated with the provided key and place it in the
@@ -471,7 +487,8 @@
*/
int32_t APersistableBundle_getIntVector(const APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, int32_t* _Nullable buffer,
- int32_t bufferSizeBytes) __INTRODUCED_IN(__ANDROID_API_V__);
+ int32_t bufferSizeBytes) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Get an int64_t vector associated with the provided key and place it in the
@@ -497,8 +514,8 @@
*/
int32_t APersistableBundle_getLongVector(const APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, int64_t* _Nullable buffer,
- int32_t bufferSizeBytes)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ int32_t bufferSizeBytes) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Get a double vector associated with the provided key and place it in the
@@ -525,7 +542,7 @@
int32_t APersistableBundle_getDoubleVector(const APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key, double* _Nullable buffer,
int32_t bufferSizeBytes)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get a string vector associated with the provided key and place it in the
@@ -562,12 +579,12 @@
int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
void* _Nullable context)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get an APersistableBundle* associated with the provided key.
*
- * Available since API level __ANDROID_API_V__.
+ * Available since API level 202404.
*
* \param pBundle to operate on
* \param key for the mapping in UTF-8
@@ -581,7 +598,7 @@
bool APersistableBundle_getPersistableBundle(const APersistableBundle* _Nonnull pBundle,
const char* _Nonnull key,
APersistableBundle* _Nullable* _Nonnull outBundle)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -614,7 +631,7 @@
int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
void* _Nullable context)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -645,7 +662,8 @@
int32_t APersistableBundle_getIntKeys(const APersistableBundle* _Nonnull pBundle,
char* _Nullable* _Nullable outKeys, int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
- void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__);
+ void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -676,7 +694,8 @@
int32_t APersistableBundle_getLongKeys(const APersistableBundle* _Nonnull pBundle,
char* _Nullable* _Nullable outKeys, int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
- void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__);
+ void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -708,8 +727,8 @@
char* _Nullable* _Nullable outKeys,
int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
- void* _Nullable context)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -741,8 +760,8 @@
char* _Nullable* _Nullable outKeys,
int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
- void* _Nullable context)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__)
+ __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -775,7 +794,7 @@
int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
void* _Nullable context)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -808,7 +827,7 @@
int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
void* _Nullable context)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -841,7 +860,7 @@
int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
void* _Nullable context)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -873,7 +892,7 @@
int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
void* _Nullable context)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -906,7 +925,7 @@
int32_t bufferSizeBytes,
APersistableBundle_stringAllocator stringAllocator,
void* _Nullable context)
- __INTRODUCED_IN(__ANDROID_API_V__);
+ __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
/**
* Get all of the keys associated with this specific type and place it in the
@@ -937,6 +956,6 @@
int32_t APersistableBundle_getPersistableBundleKeys(
const APersistableBundle* _Nonnull pBundle, char* _Nullable* _Nullable outKeys,
int32_t bufferSizeBytes, APersistableBundle_stringAllocator stringAllocator,
- void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__);
+ void* _Nullable context) __INTRODUCED_IN(__ANDROID_API_V__) __INTRODUCED_IN_LLNDK(202404);
__END_DECLS