react-native-navigation的迁移库

RNNOptions.m 320B

12345678910111213141516171819
  1. #import "RNNOptions.h"
  2. @implementation RNNOptions
  3. -(instancetype)initWithDict:(NSDictionary *)dict {
  4. self = [super init];
  5. [self mergeWith:dict];
  6. return self;
  7. }
  8. -(void)mergeWith:(NSDictionary *)otherOptions {
  9. for (id key in otherOptions) {
  10. [self setValue:[otherOptions objectForKey:key] forKey:key];
  11. }
  12. }
  13. @end