Merge pull request #1109 from adbre/iss358
[mono.git] / mcs / class / corlib / System.Runtime.InteropServices / _EventInfo.cs
1 //
2 // System.Runtime.InteropServices._EventInfo interface
3 //
4 // Author:
5 //   Kazuki Oikawa  (kazuki@panicode.com)
6 //
7
8 using System;
9 using System.Reflection;
10
11 namespace System.Runtime.InteropServices
12 {
13         [CLSCompliant (false)]
14         [InterfaceType (ComInterfaceType.InterfaceIsIUnknown)]
15         [Guid ("9DE59C64-D889-35A1-B897-587D74469E5B")]
16 #if !FULL_AOT_RUNTIME
17         [TypeLibImportClass (typeof (EventInfo))]
18 #endif
19         [ComVisible (true)]
20         public interface _EventInfo
21         {
22                 void AddEventHandler (object target, Delegate handler);
23
24                 bool Equals (object other);
25
26                 MethodInfo GetAddMethod ();
27
28                 MethodInfo GetAddMethod (bool nonPublic);
29
30                 object[] GetCustomAttributes (bool inherit);
31
32                 object[] GetCustomAttributes (Type attributeType, bool inherit);
33
34                 int GetHashCode ();
35
36                 void GetIDsOfNames ([In] ref Guid riid, IntPtr rgszNames, uint cNames, uint lcid, IntPtr rgDispId);
37
38                 void GetTypeInfo (uint iTInfo, uint lcid, IntPtr ppTInfo);
39
40                 void GetTypeInfoCount (out uint pcTInfo);
41
42                 void Invoke (uint dispIdMember, [In] ref Guid riid, uint lcid, short wFlags, IntPtr pDispParams,
43                         IntPtr pVarResult, IntPtr pExcepInfo, IntPtr puArgErr);
44
45                 MethodInfo GetRaiseMethod ();
46
47                 MethodInfo GetRaiseMethod (bool nonPublic);
48
49                 MethodInfo GetRemoveMethod ();
50
51                 MethodInfo GetRemoveMethod (bool nonPublic);
52
53                 Type GetType ();
54
55                 bool IsDefined (Type attributeType, bool inherit);
56
57                 void RemoveEventHandler (object target, Delegate handler);
58
59                 string ToString ();
60
61                 EventAttributes Attributes {get;}
62
63                 Type DeclaringType {get;}
64
65                 Type EventHandlerType {get;}
66
67                 bool IsMulticast {get;}
68
69                 bool IsSpecialName {get;}
70
71                 MemberTypes MemberType {get;}
72
73                 string Name {get;}
74
75                 Type ReflectedType {get;}
76         }
77 }