当前仓库属于关闭状态,部分功能使用受限,详情请查阅 仓库状态说明
1 Star 1 Fork 5.3K

fork_ohos_wj / docs
关闭

forked from OpenHarmony / docs 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
message-h.md 8.23 KB
一键复制 编辑 原始数据 按行查看 历史
wenjun 提交于 2020-09-08 10:08 . add OpenHarmony 1.0 baseline

message.h

Overview

Related Modules:

Samgr

Description:

Provides message communication APIs that help you to implement asynchronous functions of IUnknown.

This API is used to implement asynchronous functions of IUnknown.

Since:

1.0

Version:

1.0

Summary

Data Structures

Data Structure Name

Description

Identity

Identifies a service and feature.

Request

Defines a request.

Response

Defines a response.

Typedefs

Typedef Name

Description

Handler) (const Request *request, const Response *response)

typedef void(*

Handles asynchronous responses.

Functions

Function Name

Description

SAMGR_SendRequest (const Identity *identity, const Request *request, Handler handler)

int32

Sends a request to a service or feature of a specified identity.

SAMGR_SendSharedRequest (const Identity *identity, const Request *request, uint32 *token, Handler handler)

uint32 *

Sends a request to multiple services or features to save memory.

SAMGR_SendSharedDirectRequest (const Identity *id, const Request *req, const Response *resp, uint32 **ref, Handler handler)

int32

Sends a request and response of a caller to the feature thread. The handler is directly called to process the request and response without using the message processing functions. (Customized function for the broadcast service)

SAMGR_SendResponse (const Request *request, const Response *response)

int32

Sends a response after processing a request.

SAMGR_SendResponseByIdentity (const Identity *id, const Request *request, const Response *response)

int32

Sends a response to a specified service or feature after processing the original request. (Customized function for bootstrap)

1
https://gitee.com/fork_ohos_wj/docs.git
git@gitee.com:fork_ohos_wj/docs.git
fork_ohos_wj
docs
docs
master

搜索帮助