WebTracerProvider constructor

WebTracerProvider({
  1. List<SpanProcessor>? processors,
  2. Resource? resource,
  3. Sampler? sampler,
  4. TimeProvider? timeProvider,
  5. IdGenerator? idGenerator,
  6. SpanLimits? spanLimits,
})

Implementation

WebTracerProvider(
    {List<sdk.SpanProcessor>? processors,
    sdk.Resource? resource,
    sdk.Sampler? sampler,
    sdk.TimeProvider? timeProvider,
    api.IdGenerator? idGenerator,
    sdk.SpanLimits? spanLimits})
    : _timeProvider = timeProvider ?? sdk.DateTimeTimeProvider(),
      super(
          processors: processors ??
              [], // Default to a TracerProvider which does not emit traces.
          resource: resource ?? sdk.Resource([]),
          sampler: sampler ?? sdk.ParentBasedSampler(sdk.AlwaysOnSampler()),
          idGenerator: idGenerator ?? sdk.IdGenerator(),
          spanLimits: spanLimits ?? sdk.SpanLimits());