@Test public void shouldExtractServiceName() { String fullName = "Foo/1234/Bar"; assertThat(GrpcHelper.extractServiceName(fullName), is("Foo")); }
public static String extractServiceName(String fullMethodName) { int index = fullMethodName.indexOf('/'); return index == -1 ? fullMethodName : fullMethodName.substring(0, index); }
GrpcHelper { public static String extractServiceName(String fullMethodName) { int index = fullMethodName.indexOf('/'); return index == -1 ? fullMethodName : fullMethodName.substring(0, index); } }
GrpcHelper { public static String extractServiceName(String fullMethodName) { int index = fullMethodName.indexOf('/'); return index == -1 ? fullMethodName : fullMethodName.substring(0, index); } private  GrpcHelper(); }
GrpcHelper { public static String extractServiceName(String fullMethodName) { int index = fullMethodName.indexOf('/'); return index == -1 ? fullMethodName : fullMethodName.substring(0, index); } private  GrpcHelper(); static String extractServiceName(String fullMethodName); static String extractNamePrefix(String fullMethodName); static String extractMethodName(String fullMethodName); static Http.ResponseStatus toHttpResponseStatus(StatusException ex); static Http.ResponseStatus toHttpResponseStatus(StatusRuntimeException ex); static Http.ResponseStatus toHttpResponseStatus(Status status); static Throwable ensureStatusException(Throwable thrown, Status status); static StatusRuntimeException ensureStatusRuntimeException(Throwable thrown, Status status); }
GrpcHelper { public static String extractServiceName(String fullMethodName) { int index = fullMethodName.indexOf('/'); return index == -1 ? fullMethodName : fullMethodName.substring(0, index); } private  GrpcHelper(); static String extractServiceName(String fullMethodName); static String extractNamePrefix(String fullMethodName); static String extractMethodName(String fullMethodName); static Http.ResponseStatus toHttpResponseStatus(StatusException ex); static Http.ResponseStatus toHttpResponseStatus(StatusRuntimeException ex); static Http.ResponseStatus toHttpResponseStatus(Status status); static Throwable ensureStatusException(Throwable thrown, Status status); static StatusRuntimeException ensureStatusRuntimeException(Throwable thrown, Status status);  }