| 27 | } |
| 28 | |
| 29 | RPCFactoryRegistry::RPCFactoryFn* RPCFactoryRegistry::Get( |
| 30 | const string& protocol) { |
| 31 | auto found = fns_.find(protocol); |
| 32 | if (found == fns_.end()) return nullptr; |
| 33 | return &found->second; |
| 34 | } |
| 35 | |
| 36 | void RPCFactoryRegistry::Register(const string& protocol, |
| 37 | const RPCFactoryFn& factory_fn) { |