@Test(expected = IllegalArgumentException.class) public void findServiceMethod2() { ServiceRegistry registry = new ServiceRegistry(); ServiceMethod serviceMethod = registry.findServiceMethod("math/add"); }
public ServiceMethod findServiceMethod(String serviceName, String methodName) { Service service = findService(serviceName); if (service == null) { return null; } return service.getServiceMethods().get(methodName); }
ServiceRegistry { public ServiceMethod findServiceMethod(String serviceName, String methodName) { Service service = findService(serviceName); if (service == null) { return null; } return service.getServiceMethods().get(methodName); } }
ServiceRegistry { public ServiceMethod findServiceMethod(String serviceName, String methodName) { Service service = findService(serviceName); if (service == null) { return null; } return service.getServiceMethods().get(methodName); }  }
ServiceRegistry { public ServiceMethod findServiceMethod(String serviceName, String methodName) { Service service = findService(serviceName); if (service == null) { return null; } return service.getServiceMethods().get(methodName); }  static ServiceRegistry getDefault(); void registerService(Service service); void registerServices(ServiceProvider serviceProvider); Set<String> getRegisteredServiceNames(); Service findService(String name); ServiceMethod findServiceMethod(String serviceName, String methodName); ServiceMethod findServiceMethod(String fullName); void close(); }
ServiceRegistry { public ServiceMethod findServiceMethod(String serviceName, String methodName) { Service service = findService(serviceName); if (service == null) { return null; } return service.getServiceMethods().get(methodName); }  static ServiceRegistry getDefault(); void registerService(Service service); void registerServices(ServiceProvider serviceProvider); Set<String> getRegisteredServiceNames(); Service findService(String name); ServiceMethod findServiceMethod(String serviceName, String methodName); ServiceMethod findServiceMethod(String fullName); void close();  }