public static string GetClassName(Type t) { ManagementClassMapAttribute a = Attribute.GetCustomAttribute(t, typeof(ManagementClassMapAttribute)) as ManagementClassMapAttribute; return(a?.ClassName); }
public static ManagementPath GetManagementPath(Type t) { ManagementClassMapAttribute a = Attribute.GetCustomAttribute(t, typeof(ManagementClassMapAttribute)) as ManagementClassMapAttribute; return(a?.Path); }
public static string GetNamespacePath(Type t) { ManagementClassMapAttribute a = Attribute.GetCustomAttribute(t, typeof(ManagementClassMapAttribute)) as ManagementClassMapAttribute; return(a?.NamespacePath); }