APIScriptMessage Class Reference

Inherits from NSObject
Declared in APIScriptMessage.h

Overview

html页面调用api.accessNative方法后,引擎将其转换成了原生识别的对象

  name

此次消息的名称,对应调用api.accessNative时的name参数

@property (nonatomic, copy, readonly) NSString *name

Discussion

此次消息的名称,对应调用api.accessNative时的name参数

Declared In

APIScriptMessage.h

  userInfo

此次消息的附加信息,对应调用api.accessNative时的extra参数

@property (nonatomic, copy, readonly) id userInfo

Discussion

此次消息的附加信息,对应调用api.accessNative时的extra参数

Declared In

APIScriptMessage.h

  callback

此次消息的回调方法,通过APIWebView进行回调数据时需要

@property (nonatomic, readonly) NSInteger callback

Discussion

此次消息的回调方法,通过APIWebView进行回调数据时需要

Declared In

APIScriptMessage.h

– callbackWithRet:err:delete:

回调数据给js

- (void)callbackWithRet:(id)ret err:(id)err delete:(BOOL)del

Parameters

ret

成功数据

err

失败数据

del

是否删除回传通道

Discussion

回调数据给js

Declared In

APIScriptMessage.h