【发布时间】:2010-10-29 08:23:38
【问题描述】:
我需要从自定义属性中找到应用自定义属性的属性类型。
例如:
[MyAttribute]
string MyProperty{get;set;}
给定 MyAttribute 的实例,我如何获得 MyProperty 的类型描述符?
换句话说,我正在寻找 System.Type.GetCustomAttributes() 的反面
【问题讨论】:
-
你最好把你想做的事说出来,因为你问的是不可能的。
标签: c# reflection attributes