Merge branch 'alexischr/nursery-canaries-managed-alloc'
[mono.git] / mcs / class / corlib / System.Diagnostics.Tracing / EventSource.cs
index 0872f01977ad44dbd72aad695444439c989a2e57..bb1b719404a992efd5277abda3f6909cdecc3ede 100644 (file)
@@ -28,6 +28,7 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
+using System.Collections.Generic;
 
 namespace System.Diagnostics.Tracing
 {
@@ -76,6 +77,11 @@ namespace System.Diagnostics.Tracing
                {
                }
 
+               ~EventSource ()
+               {
+                       Dispose (false);
+               }
+
                public Exception ConstructionException
                {
                        get { return null; }
@@ -121,6 +127,7 @@ namespace System.Diagnostics.Tracing
                public void Dispose ()
                {
                        Dispose (true);
+                       GC.SuppressFinalize (this);
                }
 
                public string GetTrait (string key)
@@ -132,6 +139,10 @@ namespace System.Diagnostics.Tracing
                {
                }
 
+               public void Write (string eventName, EventSourceOptions options)
+               {
+               }
+
                public void Write<T> (string eventName, T data)
                {
                }
@@ -140,6 +151,7 @@ namespace System.Diagnostics.Tracing
                {
                }
 
+               [CLSCompliant (false)]
                public void Write<T> (string eventName, ref EventSourceOptions options, ref T data)
                {
                }
@@ -244,6 +256,77 @@ namespace System.Diagnostics.Tracing
                {
                        WriteEvent (eventId, new object[] { arg1, arg2, arg3 } );
                }
+
+               [CLSCompliant (false)]
+               protected unsafe void WriteEventCore (int eventId, int eventDataCount, EventData* data)
+               {
+               }
+
+               protected unsafe void WriteEventWithRelatedActivityId (int eventId, Guid relatedActivityId, params object[] args)
+               {
+               }
+
+               [CLSCompliant (false)]
+               protected unsafe void WriteEventWithRelatedActivityIdCore (int eventId, Guid* relatedActivityId, int eventDataCount, EventSource.EventData* data)
+               {
+               }
+
+#if NETSTANDARD
+               [MonoTODO]
+               public event EventHandler<EventCommandEventArgs> EventCommandExecuted
+               {
+                       add { throw new NotImplementedException (); }
+                       remove { throw new NotImplementedException (); }
+               }
+#endif
+
+               [MonoTODO]
+               public static string GenerateManifest (Type eventSourceType, string assemblyPathToIncludeInManifest)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [MonoTODO]
+               public static string GenerateManifest (Type eventSourceType, string assemblyPathToIncludeInManifest, EventManifestOptions flags)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [MonoTODO]
+               public static Guid GetGuid (Type eventSourceType)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [MonoTODO]
+               public static string GetName (Type eventSourceType)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [MonoTODO]
+               public static IEnumerable<EventSource> GetSources ()
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [MonoTODO]
+               public static void SendCommand (EventSource eventSource, EventCommand command, IDictionary<string, string> commandArguments)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [MonoTODO]
+               public static void SetCurrentThreadActivityId (Guid activityId)
+               {
+                       throw new NotImplementedException ();
+               }
+
+               [MonoTODO]
+               public static void SetCurrentThreadActivityId (Guid activityId, out Guid oldActivityThatWillContinue)
+               {
+                       throw new NotImplementedException ();
+               }
        }
 }