public static bool IsHiddenMethod(MethodInfo mi) { object[] MethodAttributes = mi.GetCustomAttributes(typeof(TypeLibFuncAttribute), true); if (MethodAttributes.Length > 0) { TypeLibFuncAttribute tlf = ( TypeLibFuncAttribute )MethodAttributes[0]; TypeLibFuncFlags flags = tlf.Value; return((flags & TypeLibFuncFlags.FHidden) != 0); } return(false); }
public void Ctor_ShortFlags(short flags) { var attribute = new TypeLibFuncAttribute(flags); Assert.Equal((TypeLibFuncFlags)flags, attribute.Value); }
public void Ctor_TypeLibFuncFlags(TypeLibFuncFlags flags) { var attribute = new TypeLibFuncAttribute(flags); Assert.Equal(flags, attribute.Value); }