class AbstractBasicBuilder<T extends BasicBuilder> implements BasicBuilder {

  private URI uri;
  private final Map<String, List<String>> headers = new HashMap<>();

  @Override
  public T uri(URI uri) {
    this.uri = uri;
    return (T) this;
  }

  @Override
  public T header(String name, String value) {<FILL_FUNCTION_BODY>}

  @Override
  public T setHeader(String name, String value) {
    headers.put(name, new ArrayList<>(Collections.singletonList(value)));
    return (T) this;
  }

  protected final URI getUri() {
    return uri;
  }

  protected final Map<String, List<String>> getHeaders() {
    return headers;
  }

  protected final void setHeaders(Map<String, List<String>> headers) {
    this.headers.clear();
    headers.forEach((header, values) -> values.forEach(value -> header(header, value)));
  }
}

    headers.compute(name, (k, v) -> {
      if (v == null) {
        v = new ArrayList<>();
      }
      v.add(value);
      return v;
    });
    return (T) this;
  
<no_super_class>