Line data Source code
1 : // Licensed under the Apache License, Version 2.0
2 : // Copyright 2025, Michael Bushe, All rights reserved.
3 :
4 : part of 'tracer_provider.dart';
5 :
6 : /// Factory for creating TracerProvider instances.
7 : ///
8 : /// This factory class provides a static create method for constructing
9 : /// properly configured TracerProvider instances. It follows the factory
10 : /// pattern to separate the construction logic from the TracerProvider
11 : /// class itself.
12 : class SDKTracerProviderCreate {
13 : /// Creates a new TracerProvider with the specified delegate and resource.
14 : ///
15 : /// @param delegate The API TracerProvider implementation to delegate to
16 : /// @param resource Optional Resource describing the entity producing telemetry
17 : /// @return A new TracerProvider instance
18 73 : static TracerProvider create(
19 : {required APITracerProvider delegate, Resource? resource}) {
20 73 : return TracerProvider._(delegate: delegate, resource: resource);
21 : }
22 : }
|