首先要这样定义:

[map from:@"x://profile/(initWithId:)/(name:)" toViewController:[ProfileViewController class]];
[map from:@"*" toViewController:[TTWebController class]];

我在 ProfileViewController  中实现  - (id)initWithId:(int)anIdentifier name:(NSString *)name 来处理这种映射的选择器。

这样做的效果相当于调用

[[ProfileViewController alloc] initWithId:1 name:@"John Doe"] 来初始化控制器

相关文章:

  • 2021-04-18
  • 2022-12-23
  • 2021-10-11
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-07-11
  • 2021-11-19
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-03
相关资源
相似解决方案