public PropertyInfoItemASM(IPropertyInfo property, bool allowNullEquivalentValue) : base(property, allowNullEquivalentValue) { if (property.IsReadable) { getDelegate = TypeUtility.GetMemberGetDelegate(property.DeclaringType, property.Name); } if (property.IsWritable) { setDelegate = TypeUtility.GetMemberSetDelegate(property.DeclaringType, property.Name); } }
public MethodPropertyInfoASM(Type entityType, String propertyName, MethodInfo getter, MethodInfo setter) : base(entityType, propertyName, getter, setter) { if (Getter != null) { getDelegate = TypeUtility.GetMemberGetDelegate(getter.DeclaringType, getter.Name); } if (Getter != null) { setDelegate = TypeUtility.GetMemberSetDelegate(setter.DeclaringType, setter.Name); } IsReadable = getDelegate != null; IsWritable = setDelegate != null; }
public override void RefreshAccessors(Type realType) { base.RefreshAccessors(realType); if (Getter != null) { getDelegate = TypeUtility.GetMemberGetDelegate(Getter.DeclaringType, Getter.Name); } if (Getter != null) { setDelegate = TypeUtility.GetMemberSetDelegate(Getter.DeclaringType, Setter.Name); } IsReadable = getDelegate != null; IsWritable = setDelegate != null; }
public FieldPropertyInfoASM(Type entityType, String propertyName, FieldInfo field) : base(entityType, propertyName, field) { getDelegate = TypeUtility.GetMemberGetDelegate(field.DeclaringType, field.Name); setDelegate = TypeUtility.GetMemberSetDelegate(field.DeclaringType, field.Name); }
public FieldInfoItemASM(FieldInfo field, bool allowNullEquivalentValue, String propertyName) : base(field, allowNullEquivalentValue, propertyName) { getDelegate = TypeUtility.GetMemberGetDelegate(field.DeclaringType, field.Name); setDelegate = TypeUtility.GetMemberSetDelegate(field.DeclaringType, field.Name); }