Remove excessive shortcut key matching in ToolStrip
[mono.git] / mcs / class / System.ComponentModel.Composition / src / ComponentModel / Microsoft / Internal / SilverlightReflectionInvoke.cs
1 #if SILVERLIGHT || !CLR40\r
2 \r
3 using System;\r
4 using System.Reflection;\r
5 using System.Security;\r
6 using System.Security.Permissions;\r
7 \r
8 namespace Microsoft.Internal\r
9 {\r
10     internal static class ReflectionInvoke\r
11     {\r
12         public static object SafeCreateInstance(this Type type, params object[] arguments)\r
13         {\r
14             return Activator.CreateInstance(type, arguments);\r
15         }\r
16 \r
17         public static object SafeInvoke(this ConstructorInfo constructor, params object[] arguments)\r
18         {\r
19             return constructor.Invoke(arguments);\r
20         }\r
21 \r
22         public static object SafeInvoke(this MethodInfo method, object instance, params object[] arguments)\r
23         {\r
24             return method.Invoke(instance, arguments);\r
25         }\r
26 \r
27         public static object SafeGetValue(this FieldInfo field, object instance)\r
28         {\r
29             return field.GetValue(instance);\r
30         }\r
31 \r
32         public static void SafeSetValue(this FieldInfo field, object instance, object value)\r
33         {\r
34             field.SetValue(instance, value);\r
35         }\r
36 \r
37         public static void DemandMemberAccessIfNeeded(MethodInfo method)\r
38         {\r
39         }\r
40     }\r
41 }\r
42 \r
43 #endif