aboutsummaryrefslogtreecommitdiffstatsci
path: root/src/CompilerServices/CompilerServices.cs
diff options
context:
space:
mode:
authorjpbruyere <jp.bruyere@hotmail.com>2016-12-15 18:32:52 +0100
committerjpbruyere <jp.bruyere@hotmail.com>2016-12-15 18:32:52 +0100
commit0819cdcf926fe7d54e85cbee440c2b334676b2b3 (patch)
treefb02c6ddc20fe8ad1d3966f9d0819c9d98aab93f /src/CompilerServices/CompilerServices.cs
parentaba894f6a5bb41200e969ccdd7045800ff36e74a (diff)
emit bind datasource handler methods
modifié : src/CompilerServices/CompilerServices.cs modifié : src/IML/Context.cs modifié : src/Instantiator.cs
Diffstat (limited to 'src/CompilerServices/CompilerServices.cs')
-rw-r--r--src/CompilerServices/CompilerServices.cs7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/CompilerServices/CompilerServices.cs b/src/CompilerServices/CompilerServices.cs
index 731d1b5e..ba824c62 100644
--- a/src/CompilerServices/CompilerServices.cs
+++ b/src/CompilerServices/CompilerServices.cs
@@ -28,6 +28,7 @@ namespace Crow
public static MethodInfo miCreateExpDel = typeof(ItemTemplate).GetMethod ("CreateExpandDelegate");
public static MethodInfo miLoadDefaultVals = typeof (GraphicObject).GetMethod ("loadDefaultValues");
public static PropertyInfo piStyle = typeof (GraphicObject).GetProperty ("Style");
+ public static MethodInfo miGetTypeFromHandle = typeof(Type).GetMethod("GetTypeFromHandle");
#region tree handling methods
internal static MethodInfo miSetChild = typeof (Container).GetMethod ("SetChild");
internal static MethodInfo miAddChild = typeof (Group).GetMethod ("AddChild");
@@ -635,6 +636,12 @@ namespace Crow
public static MemberInfo getMemberInfoWithReflexion(object instance, string member){
return instance.GetType ().GetMember (member).FirstOrDefault();
}
+ public static MethodInfo getMethodInfoWithReflexion(object instance, string method){
+ return instance.GetType ().GetMethod (method, BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.Public);
+ }
+ public static Type getEventHandlerType(object instance, string eventName){
+ return instance.GetType ().GetEvent (eventName).EventHandlerType;
+ }
public static object getValueWithReflexion(object instance, MemberInfo mi){
object tmp = null;
Type dstType = null;