1 // Licensed to the .NET Foundation under one or more agreements. 2 // The .NET Foundation licenses this file to you under the MIT license. 3 // See the LICENSE file in the project root for more information. 4 // ------------------------------------------------------------------------------ 5 // Changes to this file must follow the http://aka.ms/api-review process. 6 // ------------------------------------------------------------------------------ 7 8 9 namespace System.Diagnostics 10 { 11 public partial class BooleanSwitch : System.Diagnostics.Switch 12 { BooleanSwitch(string displayName, string description)13 public BooleanSwitch(string displayName, string description) : base(default(string), default(string)) { } BooleanSwitch(string displayName, string description, string defaultSwitchValue)14 public BooleanSwitch(string displayName, string description, string defaultSwitchValue) : base(default(string), default(string)) { } 15 public bool Enabled { get { throw null; } set { } } OnValueChanged()16 protected override void OnValueChanged() { } 17 } 18 public partial class CorrelationManager 19 { CorrelationManager()20 internal CorrelationManager() { } 21 public System.Guid ActivityId { get { throw null; } set { } } 22 public System.Collections.Stack LogicalOperationStack { get { throw null; } } StartLogicalOperation()23 public void StartLogicalOperation() { } StartLogicalOperation(object operationId)24 public void StartLogicalOperation(object operationId) { } StopLogicalOperation()25 public void StopLogicalOperation() { } 26 } 27 public partial class DefaultTraceListener : System.Diagnostics.TraceListener 28 { DefaultTraceListener()29 public DefaultTraceListener() { } Fail(string message)30 public override void Fail(string message) { } Fail(string message, string detailMessage)31 public override void Fail(string message, string detailMessage) { } Write(string message)32 public override void Write(string message) { } WriteLine(string message)33 public override void WriteLine(string message) { } 34 public bool AssertUiEnabled { get { throw null; } set { } } 35 public string LogFileName { get { throw null; } set { } } 36 } 37 public partial class EventTypeFilter : System.Diagnostics.TraceFilter 38 { EventTypeFilter(System.Diagnostics.SourceLevels level)39 public EventTypeFilter(System.Diagnostics.SourceLevels level) { } 40 public System.Diagnostics.SourceLevels EventType { get { throw null; } set { } } ShouldTrace(System.Diagnostics.TraceEventCache cache, string source, System.Diagnostics.TraceEventType eventType, int id, string formatOrMessage, object[] args, object data1, object[] data)41 public override bool ShouldTrace(System.Diagnostics.TraceEventCache cache, string source, System.Diagnostics.TraceEventType eventType, int id, string formatOrMessage, object[] args, object data1, object[] data) { throw null; } 42 } 43 public partial class SourceFilter : System.Diagnostics.TraceFilter 44 { SourceFilter(string source)45 public SourceFilter(string source) { } 46 public string Source { get { throw null; } set { } } ShouldTrace(System.Diagnostics.TraceEventCache cache, string source, System.Diagnostics.TraceEventType eventType, int id, string formatOrMessage, object[] args, object data1, object[] data)47 public override bool ShouldTrace(System.Diagnostics.TraceEventCache cache, string source, System.Diagnostics.TraceEventType eventType, int id, string formatOrMessage, object[] args, object data1, object[] data) { throw null; } 48 } 49 [System.FlagsAttribute] 50 public enum SourceLevels 51 { 52 All = -1, 53 Critical = 1, 54 Error = 3, 55 Information = 15, 56 Off = 0, 57 Verbose = 31, 58 [System.ComponentModel.EditorBrowsable(System.ComponentModel.EditorBrowsableState.Advanced)] 59 ActivityTracing = 0xFF00, 60 Warning = 7, 61 } 62 public partial class SourceSwitch : System.Diagnostics.Switch 63 { SourceSwitch(string name)64 public SourceSwitch(string name) : base(default(string), default(string)) { } SourceSwitch(string displayName, string defaultSwitchValue)65 public SourceSwitch(string displayName, string defaultSwitchValue) : base(default(string), default(string)) { } 66 public System.Diagnostics.SourceLevels Level { get { throw null; } set { } } OnValueChanged()67 protected override void OnValueChanged() { } ShouldTrace(System.Diagnostics.TraceEventType eventType)68 public bool ShouldTrace(System.Diagnostics.TraceEventType eventType) { throw null; } 69 } 70 public abstract partial class Switch 71 { Switch(string displayName, string description)72 protected Switch(string displayName, string description) { } Switch(string displayName, string description, string defaultSwitchValue)73 protected Switch(string displayName, string description, string defaultSwitchValue) { } 74 public string Description { get { throw null; } } 75 public string DisplayName { get { throw null; } } 76 protected int SwitchSetting { get { throw null; } set { } } 77 protected string Value { get { throw null; } set { } } OnSwitchSettingChanged()78 protected virtual void OnSwitchSettingChanged() { } OnValueChanged()79 protected virtual void OnValueChanged() { } 80 public System.Collections.Specialized.StringDictionary Attributes { get { throw null; } } GetSupportedAttributes()81 protected virtual string[] GetSupportedAttributes() { throw null; } 82 } 83 public sealed partial class Trace 84 { 85 public static CorrelationManager CorrelationManager { get { throw null; } } Trace()86 internal Trace() { } 87 public static bool AutoFlush { get { throw null; } set { } } 88 public static int IndentLevel { get { throw null; } set { } } 89 public static int IndentSize { get { throw null; } set { } } 90 public static System.Diagnostics.TraceListenerCollection Listeners { get { throw null; } } 91 public static bool UseGlobalLock { get { throw null; } set { } } 92 [System.Diagnostics.ConditionalAttribute("TRACE")] Assert(bool condition)93 public static void Assert(bool condition) { } 94 [System.Diagnostics.ConditionalAttribute("TRACE")] Assert(bool condition, string message)95 public static void Assert(bool condition, string message) { } 96 [System.Diagnostics.ConditionalAttribute("TRACE")] Assert(bool condition, string message, string detailMessage)97 public static void Assert(bool condition, string message, string detailMessage) { } 98 [System.Diagnostics.ConditionalAttribute("TRACE")] Close()99 public static void Close() { } 100 [System.Diagnostics.ConditionalAttribute("TRACE")] Fail(string message)101 public static void Fail(string message) { } 102 [System.Diagnostics.ConditionalAttribute("TRACE")] Fail(string message, string detailMessage)103 public static void Fail(string message, string detailMessage) { } 104 [System.Diagnostics.ConditionalAttribute("TRACE")] Flush()105 public static void Flush() { } 106 [System.Diagnostics.ConditionalAttribute("TRACE")] Indent()107 public static void Indent() { } Refresh()108 public static void Refresh() { } 109 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceError(string message)110 public static void TraceError(string message) { } 111 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceError(string format, params object[] args)112 public static void TraceError(string format, params object[] args) { } 113 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceInformation(string message)114 public static void TraceInformation(string message) { } 115 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceInformation(string format, params object[] args)116 public static void TraceInformation(string format, params object[] args) { } 117 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceWarning(string message)118 public static void TraceWarning(string message) { } 119 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceWarning(string format, params object[] args)120 public static void TraceWarning(string format, params object[] args) { } 121 [System.Diagnostics.ConditionalAttribute("TRACE")] Unindent()122 public static void Unindent() { } 123 [System.Diagnostics.ConditionalAttribute("TRACE")] Write(object value)124 public static void Write(object value) { } 125 [System.Diagnostics.ConditionalAttribute("TRACE")] Write(object value, string category)126 public static void Write(object value, string category) { } 127 [System.Diagnostics.ConditionalAttribute("TRACE")] Write(string message)128 public static void Write(string message) { } 129 [System.Diagnostics.ConditionalAttribute("TRACE")] Write(string message, string category)130 public static void Write(string message, string category) { } 131 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteIf(bool condition, object value)132 public static void WriteIf(bool condition, object value) { } 133 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteIf(bool condition, object value, string category)134 public static void WriteIf(bool condition, object value, string category) { } 135 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteIf(bool condition, string message)136 public static void WriteIf(bool condition, string message) { } 137 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteIf(bool condition, string message, string category)138 public static void WriteIf(bool condition, string message, string category) { } 139 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteLine(object value)140 public static void WriteLine(object value) { } 141 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteLine(object value, string category)142 public static void WriteLine(object value, string category) { } 143 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteLine(string message)144 public static void WriteLine(string message) { } 145 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteLine(string message, string category)146 public static void WriteLine(string message, string category) { } 147 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteLineIf(bool condition, object value)148 public static void WriteLineIf(bool condition, object value) { } 149 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteLineIf(bool condition, object value, string category)150 public static void WriteLineIf(bool condition, object value, string category) { } 151 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteLineIf(bool condition, string message)152 public static void WriteLineIf(bool condition, string message) { } 153 [System.Diagnostics.ConditionalAttribute("TRACE")] WriteLineIf(bool condition, string message, string category)154 public static void WriteLineIf(bool condition, string message, string category) { } 155 } 156 public partial class TraceEventCache 157 { TraceEventCache()158 public TraceEventCache() { } 159 public System.DateTime DateTime { get { throw null; } } 160 public int ProcessId { get { throw null; } } 161 public string ThreadId { get { throw null; } } 162 public long Timestamp { get { throw null; } } 163 public string Callstack { get { throw null; } } 164 public System.Collections.Stack LogicalOperationStack { get { throw null; } } 165 } 166 public enum TraceEventType 167 { 168 Critical = 1, 169 Error = 2, 170 Information = 8, 171 Verbose = 16, 172 Warning = 4, 173 Resume = 2048, 174 Start = 256, 175 Stop = 512, 176 Suspend = 1024, 177 Transfer = 4096, 178 } 179 public abstract partial class TraceFilter 180 { TraceFilter()181 protected TraceFilter() { } ShouldTrace(System.Diagnostics.TraceEventCache cache, string source, System.Diagnostics.TraceEventType eventType, int id, string formatOrMessage, object[] args, object data1, object[] data)182 public abstract bool ShouldTrace(System.Diagnostics.TraceEventCache cache, string source, System.Diagnostics.TraceEventType eventType, int id, string formatOrMessage, object[] args, object data1, object[] data); 183 } 184 public enum TraceLevel 185 { 186 Error = 1, 187 Info = 3, 188 Off = 0, 189 Verbose = 4, 190 Warning = 2, 191 } 192 public abstract partial class TraceListener : System.MarshalByRefObject, System.IDisposable 193 { TraceListener()194 protected TraceListener() { } TraceListener(string name)195 protected TraceListener(string name) { } 196 public System.Diagnostics.TraceFilter Filter { get { throw null; } set { } } 197 public int IndentLevel { get { throw null; } set { } } 198 public int IndentSize { get { throw null; } set { } } 199 public virtual bool IsThreadSafe { get { throw null; } } 200 public virtual string Name { get { throw null; } set { } } 201 protected bool NeedIndent { get { throw null; } set { } } 202 public System.Diagnostics.TraceOptions TraceOutputOptions { get { throw null; } set { } } Dispose()203 public void Dispose() { } Dispose(bool disposing)204 protected virtual void Dispose(bool disposing) { } Fail(string message)205 public virtual void Fail(string message) { } Fail(string message, string detailMessage)206 public virtual void Fail(string message, string detailMessage) { } Flush()207 public virtual void Flush() { } TraceData(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, object data)208 public virtual void TraceData(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, object data) { } TraceData(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, params object[] data)209 public virtual void TraceData(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, params object[] data) { } TraceEvent(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id)210 public virtual void TraceEvent(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id) { } TraceEvent(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string message)211 public virtual void TraceEvent(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string message) { } TraceEvent(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string format, params object[] args)212 public virtual void TraceEvent(System.Diagnostics.TraceEventCache eventCache, string source, System.Diagnostics.TraceEventType eventType, int id, string format, params object[] args) { } Write(object o)213 public virtual void Write(object o) { } Write(object o, string category)214 public virtual void Write(object o, string category) { } Write(string message)215 public abstract void Write(string message); Write(string message, string category)216 public virtual void Write(string message, string category) { } WriteIndent()217 protected virtual void WriteIndent() { } WriteLine(object o)218 public virtual void WriteLine(object o) { } WriteLine(object o, string category)219 public virtual void WriteLine(object o, string category) { } WriteLine(string message)220 public abstract void WriteLine(string message); WriteLine(string message, string category)221 public virtual void WriteLine(string message, string category) { } 222 public System.Collections.Specialized.StringDictionary Attributes { get { throw null; } } Close()223 public virtual void Close() { } GetSupportedAttributes()224 protected virtual string[] GetSupportedAttributes() { throw null; } TraceTransfer(TraceEventCache eventCache, string source, int id, string message, Guid relatedActivityId)225 public virtual void TraceTransfer(TraceEventCache eventCache, string source, int id, string message, Guid relatedActivityId) { throw null; } 226 } 227 public partial class TraceListenerCollection : System.Collections.ICollection, System.Collections.IEnumerable, System.Collections.IList 228 { TraceListenerCollection()229 internal TraceListenerCollection() { } 230 public int Count { get { throw null; } } 231 public System.Diagnostics.TraceListener this[int i] { get { throw null; } set { } } 232 public System.Diagnostics.TraceListener this[string name] { get { throw null; } } 233 bool System.Collections.ICollection.IsSynchronized { get { throw null; } } 234 object System.Collections.ICollection.SyncRoot { get { throw null; } } 235 bool System.Collections.IList.IsFixedSize { get { throw null; } } 236 bool System.Collections.IList.IsReadOnly { get { throw null; } } 237 object System.Collections.IList.this[int index] { get { throw null; } set { } } Add(System.Diagnostics.TraceListener listener)238 public int Add(System.Diagnostics.TraceListener listener) { throw null; } AddRange(System.Diagnostics.TraceListener[] value)239 public void AddRange(System.Diagnostics.TraceListener[] value) { } AddRange(System.Diagnostics.TraceListenerCollection value)240 public void AddRange(System.Diagnostics.TraceListenerCollection value) { } Clear()241 public void Clear() { } Contains(System.Diagnostics.TraceListener listener)242 public bool Contains(System.Diagnostics.TraceListener listener) { throw null; } CopyTo(System.Diagnostics.TraceListener[] listeners, int index)243 public void CopyTo(System.Diagnostics.TraceListener[] listeners, int index) { } GetEnumerator()244 public System.Collections.IEnumerator GetEnumerator() { throw null; } IndexOf(System.Diagnostics.TraceListener listener)245 public int IndexOf(System.Diagnostics.TraceListener listener) { throw null; } Insert(int index, System.Diagnostics.TraceListener listener)246 public void Insert(int index, System.Diagnostics.TraceListener listener) { } Remove(System.Diagnostics.TraceListener listener)247 public void Remove(System.Diagnostics.TraceListener listener) { } Remove(string name)248 public void Remove(string name) { } RemoveAt(int index)249 public void RemoveAt(int index) { } System.Collections.ICollection.CopyTo(System.Array array, int index)250 void System.Collections.ICollection.CopyTo(System.Array array, int index) { } System.Collections.IList.Add(object value)251 int System.Collections.IList.Add(object value) { throw null; } System.Collections.IList.Contains(object value)252 bool System.Collections.IList.Contains(object value) { throw null; } System.Collections.IList.IndexOf(object value)253 int System.Collections.IList.IndexOf(object value) { throw null; } System.Collections.IList.Insert(int index, object value)254 void System.Collections.IList.Insert(int index, object value) { } System.Collections.IList.Remove(object value)255 void System.Collections.IList.Remove(object value) { } 256 } 257 [System.FlagsAttribute] 258 public enum TraceOptions 259 { 260 DateTime = 2, 261 None = 0, 262 LogicalOperationStack = 1, 263 ProcessId = 8, 264 ThreadId = 16, 265 Timestamp = 4, 266 Callstack = 32, 267 } 268 public partial class TraceSource 269 { TraceSource(string name)270 public TraceSource(string name) { } TraceSource(string name, System.Diagnostics.SourceLevels defaultLevel)271 public TraceSource(string name, System.Diagnostics.SourceLevels defaultLevel) { } 272 public System.Diagnostics.TraceListenerCollection Listeners { get { throw null; } } 273 public string Name { get { throw null; } } 274 public System.Diagnostics.SourceSwitch Switch { get { throw null; } set { } } Close()275 public void Close() { } Flush()276 public void Flush() { } 277 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceData(System.Diagnostics.TraceEventType eventType, int id, object data)278 public void TraceData(System.Diagnostics.TraceEventType eventType, int id, object data) { } 279 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceData(System.Diagnostics.TraceEventType eventType, int id, params object[] data)280 public void TraceData(System.Diagnostics.TraceEventType eventType, int id, params object[] data) { } 281 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceEvent(System.Diagnostics.TraceEventType eventType, int id)282 public void TraceEvent(System.Diagnostics.TraceEventType eventType, int id) { } 283 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceEvent(System.Diagnostics.TraceEventType eventType, int id, string message)284 public void TraceEvent(System.Diagnostics.TraceEventType eventType, int id, string message) { } 285 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceEvent(System.Diagnostics.TraceEventType eventType, int id, string format, params object[] args)286 public void TraceEvent(System.Diagnostics.TraceEventType eventType, int id, string format, params object[] args) { } 287 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceInformation(string message)288 public void TraceInformation(string message) { } 289 [System.Diagnostics.ConditionalAttribute("TRACE")] TraceInformation(string format, params object[] args)290 public void TraceInformation(string format, params object[] args) { } 291 public System.Collections.Specialized.StringDictionary Attributes { get { throw null; } } GetSupportedAttributes()292 protected virtual string[] GetSupportedAttributes() { throw null; } TraceTransfer(int id, string message, System.Guid relatedActivityId)293 public void TraceTransfer(int id, string message, System.Guid relatedActivityId) { } 294 } 295 public partial class TraceSwitch : System.Diagnostics.Switch 296 { TraceSwitch(string displayName, string description)297 public TraceSwitch(string displayName, string description) : base(default(string), default(string)) { } TraceSwitch(string displayName, string description, string defaultSwitchValue)298 public TraceSwitch(string displayName, string description, string defaultSwitchValue) : base(default(string), default(string)) { } 299 public System.Diagnostics.TraceLevel Level { get { throw null; } set { } } 300 public bool TraceError { get { throw null; } } 301 public bool TraceInfo { get { throw null; } } 302 public bool TraceVerbose { get { throw null; } } 303 public bool TraceWarning { get { throw null; } } OnSwitchSettingChanged()304 protected override void OnSwitchSettingChanged() { } OnValueChanged()305 protected override void OnValueChanged() { } 306 } 307 public sealed class SwitchAttribute : System.Attribute 308 { SwitchAttribute(string switchName, Type switchType)309 public SwitchAttribute(string switchName, Type switchType) { throw null; } 310 public string SwitchDescription { get { throw null; } set { } } 311 public string SwitchName { get { throw null; } set { } } 312 public System.Type SwitchType { get { throw null; } set { } } GetAll(System.Reflection.Assembly assembly)313 public static SwitchAttribute[] GetAll(System.Reflection.Assembly assembly) { throw null; } 314 } 315 public sealed class SwitchLevelAttribute : System.Attribute 316 { SwitchLevelAttribute(Type switchLevelType)317 public SwitchLevelAttribute(Type switchLevelType) { throw null; } 318 public System.Type SwitchLevelType { get { throw null; } set { } } 319 } 320 } 321