optimize code
This commit is contained in:
parent
95a85af56b
commit
3ee6275cc0
@ -61,27 +61,27 @@ - (void)innerRegister {
|
|||||||
}
|
}
|
||||||
|
|
||||||
- (void)registerJSBundle:(NSString *)bundle withName:(NSString *)name {
|
- (void)registerJSBundle:(NSString *)bundle withName:(NSString *)name {
|
||||||
[self.bundles setObject:bundle forKey:name];
|
self.bundles[name] = bundle;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (NSString *)acquireJSBundle:(NSString *)name {
|
- (NSString *)acquireJSBundle:(NSString *)name {
|
||||||
return [self.bundles objectForKey:name];
|
return self.bundles[name];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)registerNativePlugin:(Class)pluginClass withName:(NSString *)name {
|
- (void)registerNativePlugin:(Class)pluginClass withName:(NSString *)name {
|
||||||
[self.plugins setObject:pluginClass forKey:name];
|
self.plugins[name] = pluginClass;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (Class)acquireNativePlugin:(NSString *)name {
|
- (Class)acquireNativePlugin:(NSString *)name {
|
||||||
return [self.plugins objectForKey:name];
|
return self.plugins[name];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void)registerViewNode:(Class)nodeClass withName:(NSString *)name {
|
- (void)registerViewNode:(Class)nodeClass withName:(NSString *)name {
|
||||||
[self.nodes setObject:nodeClass forKey:name];
|
self.nodes[name] = nodeClass;
|
||||||
}
|
}
|
||||||
|
|
||||||
- (Class)acquireViewNode:(NSString *)name {
|
- (Class)acquireViewNode:(NSString *)name {
|
||||||
return [self.nodes objectForKey:name];
|
return self.nodes[name];
|
||||||
}
|
}
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
Reference in New Issue
Block a user