IGLib
1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
|
Provides a platform-independent methods for getting attributes for use by AttributeConstraint and AttributeExistsConstraint. More...
Static Public Member Functions | |
static Attribute[] | GetCustomAttributes (object actual, Type attributeType, bool inherit) |
Gets the custom attributes from the given object. More... | |
Provides a platform-independent methods for getting attributes for use by AttributeConstraint and AttributeExistsConstraint.
|
inlinestatic |
Gets the custom attributes from the given object.
Portable libraries do not have an ICustomAttributeProvider, so we need to cast to each of it's direct subtypes and try to get attributes off those instead.
actual | The actual. |
attributeType | Type of the attribute. |
inherit | if set to true [inherit]. |
Referenced by NUnit.Framework.Constraints.AttributeConstraint.ApplyTo< TActual >(), NUnit.Framework.Constraints.AttributeExistsConstraint.ApplyTo< TActual >(), NUnit.Framework.Tests.Compatibility.AttributeHelperTests.CanGetAttributesOnAssemblies(), NUnit.Framework.Tests.Compatibility.AttributeHelperTests.CanGetAttributesOnClasses(), NUnit.Framework.Tests.Compatibility.AttributeHelperTests.CanGetAttributesOnDerivedClasses(), NUnit.Framework.Tests.Compatibility.AttributeHelperTests.CanGetAttributesOnFields(), NUnit.Framework.Tests.Compatibility.AttributeHelperTests.CanGetAttributesOnMethods(), NUnit.Framework.Tests.Compatibility.AttributeHelperTests.CanGetAttributesOnParameters(), NUnit.Framework.Tests.Compatibility.AttributeHelperTests.CanGetAttributesOnProperties(), and NUnit.Framework.Tests.Compatibility.AttributeHelperTests.DoesNotGetAttributesOnDerivedClassesWhenInheritedIsFalse().