Class FieldInfoIntrospectionProviderExtensions
Provides a set of extension methods for IFieldInfoIntrospectionProvider.
Inheritance
Namespace: System.Reflection
Assembly: Nuqleon.Reflection.Virtualization.dll
Syntax
public static class FieldInfoIntrospectionProviderExtensions : Object
Methods
IsAssembly(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the potential visibility of the specified field
is described by System.Reflection.FieldAttributes.Assembly; that is, the field is visible at most to other types in the same assembly, and is not visible to derived types outside the assembly.
Declaration
public static bool IsAssembly(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to retrieve visibility for. |
Returns
Type | Description |
---|---|
System.Boolean | true if the visibility of the specified |
IsFamily(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the potential visibility of the specified field
is described by System.Reflection.FieldAttributes.Family; that is, the field is visible only within its class and derived classes.
Declaration
public static bool IsFamily(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to retrieve visibility for. |
Returns
Type | Description |
---|---|
System.Boolean | true if the visibility of the specified |
IsFamilyAndAssembly(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the potential visibility of the specified field
is described by System.Reflection.FieldAttributes.FamANDAssem; that is, the field can be accessed from derived classes, but only if they are in the same assembly.
Declaration
public static bool IsFamilyAndAssembly(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to retrieve visibility for. |
Returns
Type | Description |
---|---|
System.Boolean | true if the visibility of the specified |
IsFamilyOrAssembly(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the potential visibility of the specified field
is described by System.Reflection.FieldAttributes.FamORAssem; that is, the field can be accessed by derived classes wherever they are, and by classes in the same assembly.
Declaration
public static bool IsFamilyOrAssembly(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to retrieve visibility for. |
Returns
Type | Description |
---|---|
System.Boolean | true if the visibility of the specified |
IsInitOnly(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the field can only be set in the body of the constructor.
Declaration
public static bool IsInitOnly(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to inspect. |
Returns
Type | Description |
---|---|
System.Boolean | true if the field has the InitOnly attribute set; otherwise, false. |
IsLiteral(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the value is written at compile time and cannot be changed.
Declaration
public static bool IsLiteral(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to inspect. |
Returns
Type | Description |
---|---|
System.Boolean | true if the field has the Literal attribute set; otherwise, false. |
IsNotSerialized(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the field has the NotSerialized attribute.
Declaration
public static bool IsNotSerialized(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to inspect. |
Returns
Type | Description |
---|---|
System.Boolean | true if the field has the NotSerialized attribute set; otherwise, false. |
IsPinvokeImpl(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the field has the PinvokeImpl attribute.
Declaration
public static bool IsPinvokeImpl(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to inspect. |
Returns
Type | Description |
---|---|
System.Boolean | true if the field has the PinvokeImpl attribute set; otherwise, false. |
IsPrivate(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the field is private.
Declaration
public static bool IsPrivate(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to retrieve visibility for. |
Returns
Type | Description |
---|---|
System.Boolean | true if the field is private; otherwise; false. |
IsPublic(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the field is public.
Declaration
public static bool IsPublic(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to retrieve visibility for. |
Returns
Type | Description |
---|---|
System.Boolean | true if the field is public; otherwise; false. |
IsSpecialName(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the field has the SpecialName attribute.
Declaration
public static bool IsSpecialName(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to inspect. |
Returns
Type | Description |
---|---|
System.Boolean | true if the field has the SpecialName attribute set; otherwise, false. |
IsStatic(IFieldInfoIntrospectionProvider, FieldInfo)
Gets a value indicating whether the field is static..
Declaration
public static bool IsStatic(this IFieldInfoIntrospectionProvider provider, FieldInfo field)
Parameters
Type | Name | Description |
---|---|---|
IFieldInfoIntrospectionProvider | provider | The reflection introspection provider. |
System.Reflection.FieldInfo | field | The field to inspect. |
Returns
Type | Description |
---|---|
System.Boolean | true if the field is static; otherwise, false. |