mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-05-08 07:53:15 +08:00
Prepare the bridge for C++
Reviewed By: @nicklockwood Differential Revision: D2432291
This commit is contained in:
committed by
facebook-github-bot-8
parent
18a7e363b5
commit
a87ba4ab4c
@@ -50,8 +50,11 @@ typedef BOOL (^RCTArgumentBlock)(RCTBridge *, NSUInteger, id);
|
||||
NSArray *_argumentBlocks;
|
||||
NSString *_objCMethodName;
|
||||
SEL _selector;
|
||||
NSDictionary *_profileArgs;
|
||||
}
|
||||
|
||||
@synthesize JSMethodName = _JSMethodName;
|
||||
|
||||
static void RCTLogArgumentError(RCTModuleMethod *method, NSUInteger index,
|
||||
id valueOrType, const char *issue)
|
||||
{
|
||||
@@ -370,6 +373,19 @@ void RCTParseObjCMethodName(NSString **objCMethodName, NSArray **arguments)
|
||||
return _selector;
|
||||
}
|
||||
|
||||
- (NSDictionary *)profileArgs
|
||||
{
|
||||
if (_profileArgs) {
|
||||
// This sets _selector
|
||||
[self processMethodSignature];
|
||||
_profileArgs = @{
|
||||
@"module": NSStringFromClass(_moduleClass),
|
||||
@"selector": NSStringFromSelector(_selector),
|
||||
};
|
||||
}
|
||||
return _profileArgs;
|
||||
}
|
||||
|
||||
- (void)invokeWithBridge:(RCTBridge *)bridge
|
||||
module:(id)module
|
||||
arguments:(NSArray *)arguments
|
||||
|
||||
Reference in New Issue
Block a user