code: func NewTracer(rep reporter.Reporter, opts ...TracerOption) (*Tracer, error) {
  	// set default tracer options
  	t := &Tracer{
  		defaultTags:          make(map[string]string),
  		extractFailurePolicy: ExtractFailurePolicyRestart,
  		sampler:              AlwaysSample,
  		generate:             idgenerator.NewRandom64(),
  		reporter:             rep,
  		localEndpoint:        nil,
  		noop:                 0,
  		sharedSpans:          true,
  		unsampledNoop:        false,
  	}
  
  	// if no reporter was provided we default to noop implementation.
  	if t.reporter == nil {
  		t.reporter = reporter.NewNoopReporter()
  		t.noop = 1
  	}
  
  	// process functional options
  	for _, opt := range opts {
  		if err := opt(t); err != nil {
  			return nil, err
  		}
  	}
  
  	return t, nil
  }
docs: // NewTracer returns a new Zipkin Tracer.