C# 判断属性是否泛型
C# 判断属性是否泛型C# Code: var ps = obj.GetType().GetProperties(BindingFlags.Instance | BindingFlags.Public);
foreach (PropertyInfo p in ps)
{
//泛型属性:判断泛型参数>0
if (p.PropertyType.GenericTypeArguments.Length > 0)
{
}
}
//来源:C/S框架网 | www.csframework.com | QQ:23404761
扫一扫加作者微信