diff --git a/distributeddatamgr/relational_store/include/relational_store.h b/distributeddatamgr/relational_store/include/relational_store.h index 57daa9ea3ab4add5917e892deb585bcbcb59a151..81f2c6e468d54c222b863954dfa2bb865f9bd5f8 100644 --- a/distributeddatamgr/relational_store/include/relational_store.h +++ b/distributeddatamgr/relational_store/include/relational_store.h @@ -411,6 +411,19 @@ int OH_Rdb_SetTokenizer(OH_Rdb_ConfigV2 *config, Rdb_Tokenizer tokenizer); */ int OH_Rdb_SetPersistent(OH_Rdb_ConfigV2 *config, bool isPersistent); +/** + * @brief Set whether the database enable the capabilities for semantic indexing processing. + * + * @param config Represents a pointer to {@link OH_Rdb_ConfigV2} instance. + * Indicates the configuration of the database related to this RDB store. + * @param enableSemanticIndex Indicates whether the database enable the capabilities for semantic indexing processing. + * @return Returns the status code of the execution. Successful execution returns RDB_OK, + * {@link RDB_OK} - success. + * {@link RDB_E_INVALID_ARGS} - The error code for common invalid args. + * @since 20 + */ +int OH_Rdb_SetSemanticIndex(OH_Rdb_ConfigV2 *config, bool enableSemanticIndex); + /** * @brief Check if a tokenizer is supported or not. * diff --git a/distributeddatamgr/relational_store/libnative_rdb.ndk.json b/distributeddatamgr/relational_store/libnative_rdb.ndk.json index 297caefed1cc756a8d52f1072546faa0f343665e..fd3614309c9740248db2ace990f2665b477968e6 100644 --- a/distributeddatamgr/relational_store/libnative_rdb.ndk.json +++ b/distributeddatamgr/relational_store/libnative_rdb.ndk.json @@ -44,6 +44,10 @@ "first_introduced": "14", "name":"OH_Rdb_SetDbType" }, + { + "first_introduced": "20", + "name":"OH_Rdb_SetSemanticIndex" + }, { "first_introduced": "17", "name":"OH_Rdb_SetTokenizer"