@Test public void parseHeaders() throws Exception { HttpHeadersMap headersMap = new HttpHeadersMap() .put("X-Grpc-RateLimit", "128") .put("Content-Type", "application/json"); Metadata headers = RequestParser.parseHeaders(headersMap); assertThat(headers.get(Metadata.Key.of("X-Grpc-RateLimit", Metadata.ASCII_STRING_MARSHALLER))) .isEqualTo("128"); assertThat(headers.get(Metadata.Key.of("Content-Type", Metadata.ASCII_STRING_MARSHALLER))) .isEqualTo("application/json"); }
public static <T extends AbstractStub<T>> T parseHeaders(HttpHeaders headers, T stub) { return MetadataUtils.attachHeaders(stub, parseHeaders(headers)); }
RequestParser { public static <T extends AbstractStub<T>> T parseHeaders(HttpHeaders headers, T stub) { return MetadataUtils.attachHeaders(stub, parseHeaders(headers)); } }
RequestParser { public static <T extends AbstractStub<T>> T parseHeaders(HttpHeaders headers, T stub) { return MetadataUtils.attachHeaders(stub, parseHeaders(headers)); }  }
RequestParser { public static <T extends AbstractStub<T>> T parseHeaders(HttpHeaders headers, T stub) { return MetadataUtils.attachHeaders(stub, parseHeaders(headers)); }  static void parseQueryParams(UriInfo uriInfo,
            V.Builder builder,
            DescriptorProtos.FieldDescriptorProto... pathParams); static void parseQueryParams(UriInfo uriInfo,
            V.Builder builder,
            List<DescriptorProtos.FieldDescriptorProto> pathParams); static T parseHeaders(HttpHeaders headers, T stub); static Metadata parseHeaders(HttpHeaders headers); static void setFieldSafely(Message.Builder builder, String path, String value); static void setFieldSafely(Message.Builder builder, String path, List<String> value); static void setFieldSafely(Message.Builder builder, Descriptors.FieldDescriptor fd, List<String> value); static void handleBody(
            String fieldPath,
            V.Builder builder,
            String body); }
RequestParser { public static <T extends AbstractStub<T>> T parseHeaders(HttpHeaders headers, T stub) { return MetadataUtils.attachHeaders(stub, parseHeaders(headers)); }  static void parseQueryParams(UriInfo uriInfo,
            V.Builder builder,
            DescriptorProtos.FieldDescriptorProto... pathParams); static void parseQueryParams(UriInfo uriInfo,
            V.Builder builder,
            List<DescriptorProtos.FieldDescriptorProto> pathParams); static T parseHeaders(HttpHeaders headers, T stub); static Metadata parseHeaders(HttpHeaders headers); static void setFieldSafely(Message.Builder builder, String path, String value); static void setFieldSafely(Message.Builder builder, String path, List<String> value); static void setFieldSafely(Message.Builder builder, Descriptors.FieldDescriptor fd, List<String> value); static void handleBody(
            String fieldPath,
            V.Builder builder,
            String body);  }