The tracing layer wraps a trace-aware object around major services and formatters. Apps that need to downcast a service or formatter need a way to ask for the inner object instance.
Recommend design for open-ended wrapping API, not just tracing. Consider something like IWrappable<T> and Wrappable.Unwrap<T>(object). Make trace wrappers implement this and make MediaTypeFormatterCollection aware to use it.
Recommend design for open-ended wrapping API, not just tracing. Consider something like IWrappable<T> and Wrappable.Unwrap<T>(object). Make trace wrappers implement this and make MediaTypeFormatterCollection aware to use it.