// /** // * File: NativePropertyDescriptor.cs // * Author: haraldwolff // * // * This file and it's content is copyrighted by the Author and / or copyright holder. // * Any use wihtout proper permission is illegal and may lead to legal actions. // * // * // **/ using System; using System.Reflection; using System.ComponentModel; namespace ln.manage { public class NativePropertyDescriptor : PropertyDescriptor { public Action SetValue { get; } public Func GetValue { get; } public NativePropertyDescriptor(IManagedContainer managedContainer, FieldInfo fieldInfo) : base(managedContainer, fieldInfo) { GetValue = fieldInfo.GetValue; SetValue = fieldInfo.SetValue; } public NativePropertyDescriptor(IManagedContainer managedContainer, PropertyInfo propertyInfo) : base(managedContainer, propertyInfo) { GetValue = propertyInfo.GetValue; SetValue = propertyInfo.SetValue; } } }