code: static Runnable withSpan(Span span, boolean endSpan, Runnable runnable) {
      return new RunnableInSpan(span, runnable, endSpan);
    }
docs: Wraps a {@link Runnable} so that it executes with the {@code span} as the current {@code Span}.
  
  @param span the {@code Span} to be set as current.
  @param endSpan if {@code true} the returned {@code Runnable} will close the {@code Span}.
  @param runnable the {@code Runnable} to run in the {@code Span}.
  @return the wrapped {@code Runnable}.