7#include "../object.hpp"
17 namespace diagnostics {
71 const
xtd::
string& name() const noexcept;
102 template<class object_t>
105 if (source_switch_.should_trace(event_type))
106 for (
auto listener : listeners_)
117 template<
class object_t>
120 if (source_switch_.should_trace(event_type))
121 for (
auto listener : listeners_)
132 if (source_switch_.should_trace(event_type))
133 for (
auto listener : listeners_)
144 if (source_switch_.should_trace(event_type))
145 for (
auto listener : listeners_)
155 template<
class ...objects>
158 if (source_switch_.should_trace(event_type))
159 for (
auto listener : listeners_)
175 template<
class ...objects_t>
184 template<
class gu
id_t>
187 for (
auto listener : listeners_)
188 listener->trace_transfer(
trace_event_cache(), name_, id, message, related_activity_id);
194 std::map<xtd::string, xtd::string> attributes_;
Provides methods for creating, manipulating, searching, and sorting arrays, thereby serving as the ba...
Definition array.hpp:61
Represents text as a sequence of character units.
Definition basic_string.hpp:71
Provides a multilevel switch to control tracing and debug output without recompiling your code.
Definition source_switch.hpp:31
Provides trace event data specific to a thread and a process.
Definition trace_event_cache.hpp:29
Represents a collection of xtd::diagnostics::trace_listener.
Definition trace_listener_collection.hpp:29
Provides a set of methods and properties that enable applications to trace the execution of code and ...
Definition trace_source.hpp:42
xtd::diagnostics::trace_listener_collection & listeners() noexcept
Gets the collection of trace listeners for the trace source.
void trace_event(const xtd::diagnostics::trace_event_type &event_type, int32 id)
Writes a trace event message to the trace listeners in the listeners collection using the specified e...
Definition trace_source.hpp:130
void trace_event(const xtd::diagnostics::trace_event_type &event_type, int32 id, const xtd::string &format, const objects &... args)
Writes a trace event message to the trace listeners in the listeners collection using the specified e...
Definition trace_source.hpp:156
trace_source(const xtd::string &name, xtd::diagnostics::source_levels default_levels)
Initializes a new instance of the Trace_Source class, using the specified name for the source.
void trace_information(const xtd::string &format, const objects_t &... args)
Writes an informational message to the trace listeners in the listeners collection using the specifie...
Definition trace_source.hpp:176
trace_source(const xtd::string &name)
Initializes a new instance of the Trace_Source class, using the specified name for the source.
void trace_transfer(int32 id, const xtd::string &message, const guid_t &related_activity_id)
Writes a trace transfer message to the trace listeners in the listeners collection using the specifie...
Definition trace_source.hpp:185
void trace_event(const xtd::diagnostics::trace_event_type &event_type, int32 id, const xtd::string &message)
Writes a trace event message to the trace listeners in the listeners collection using the specified e...
Definition trace_source.hpp:142
void trace_information(const xtd::string &message)
Writes an informational message to the trace listeners in the listeners collection using the specifie...
void trace_data(const xtd::diagnostics::trace_event_type &event_type, int32 id, const xtd::array< object_t > &data)
Writes trace data to the trace listeners in the Listeners collection using the specified event type,...
Definition trace_source.hpp:118
Supports all classes in the xtd class hierarchy and provides low-level services to derived classes....
Definition object.hpp:43
Contains xtd::diagnostics::default_trace_listener class.
#define core_export_
Define shared library export.
Definition core_export.hpp:13
int32_t int32
Represents a 32-bit signed integer.
Definition int32.hpp:23
trace_event_type
Identifies the type of event that has caused the trace.
Definition trace_event_type.hpp:25
source_levels
Specifies the levels of trace messages filtered by the source switch and event type filter....
Definition source_levels.hpp:25
@ off
Does not allow any events through.
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition xtd_about_box.hpp:10
Contains xtd::diagnostics::source_levels enum class.
Contains xtd::diagnostics::source_switch class.
Contains xtd::diagnostics::trace_event_cache class.
Contains xtd::diagnostics::trace_listener_collection class.