update native interface defines

Signed-off-by: yan-shuifeng <yanshuifeng@huawei.com>
Change-Id: I4a9e8d9790ec4da31be2157f5c33e9f68da4ccd3
This commit is contained in:
yan-shuifeng 2024-01-31 17:02:11 +08:00
parent 9fcd740122
commit 27cf1e8092
4 changed files with 472 additions and 379 deletions

View File

@ -46,7 +46,6 @@ ColumnLimit: 120
CommentPragmas: '^ IWYU pragma:'
QualifierAlignment: Leave
ReflowComments: false
PenaltyBreakComment: 1000000
CompactNamespaces: false
ConstructorInitializerAllOnOneLineOrOnePerLine: false
ConstructorInitializerIndentWidth: 4
@ -86,7 +85,6 @@ PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 80
PointerAlignment: Left
ReflowComments: true
SortIncludes: true
SortUsingDeclarations: true
SpaceAfterCStyleCast: false

View File

@ -199,7 +199,7 @@ typedef struct {
/**
* @brief
* @param points
* @param historicalPoints
* @return
* @note
* 使delete[]

View File

@ -65,6 +65,16 @@ typedef enum {
ARKUI_NATIVE_NODE,
} ArkUI_NativeAPIVariantKind;
/**
* @brief ARKUI_NATIVE_NODE类型支持的版本号信息
*
* @since 12
*/
typedef enum {
/** ARKUI_NATIVE_NODE类型支持版本1的结构体{@link ArkUI_NativeNodeAPI_1}。*/
ARKUI_NATIVE_NODE_VERSION_1,
} ArkUI_NativeNodeAPIVersion;
/**
* @brief Native接口集合
*
@ -85,6 +95,26 @@ typedef enum {
*/
ArkUI_AnyNativeAPI* OH_ArkUI_GetNativeAPI(ArkUI_NativeAPIVariantKind type, int32_t version);
/**
* @brief Native模块接口集合
*
* @param type ArkUI提供的Native接口集合大类UI组件接口类ARKUI_NATIVE_NODE
* @param version native接口结构体的版本信息ARKUI_NATIVE_NODE的可用版本{@link ARKUI_NATIVE_NODE_VERSION_1}
* @return ArkUI_AnyNativeAPI* Native接口抽象对象
* @code {.cpp}
* #include<arkui/native_interface.h>
* #include<arkui/native_node.h>
*
* auto anyNativeAPI = OH_ArkUI_QueryModuleInterface(ARKUI_NATIVE_NODE, ARKUI_NATIVE_NODE_VERSION_1);
* if (anyNativeAPI->version == ARKUI_NATIVE_NODE_VERSION_1) {
* auto nativeNodeApi = reinterpret_cast<ArkUI_NativeNodeAPI_1*>(anyNativeAPI);
* }
* @endcode
*
* @since 12
*/
ArkUI_AnyNativeAPI* OH_ArkUI_QueryModuleInterface(ArkUI_NativeAPIVariantKind type, int32_t version);
#ifdef __cplusplus
};
#endif

File diff suppressed because it is too large Load Diff