code: public void startSpanWithParent(SpanBuilder spanBuilder, Span parent, String id) {
          if (parent != null) {
              spanBuilder.asChildOf(parent.context());
          }
  
          doStartSpan(spanBuilder, id);
      }
docs: This is a convenience method for situations where we don't know
  if a parent span is available. If we try to add a childOf relationship
  to a null parent, it would cause a null pointer exception.
  
  The optional id is associated with the started span.
  
  @param spanBuilder The span builder
  @param parent The parent span
  @param id The optional id to associate with the span