FieldInfo Properties

The FieldInfo type exposes the following members.

  Name Description
Public property Attributes Gets the attributes associated with this field.
Public property CustomAttributes Gets a collection that contains this member's custom attributes. (Inherited from MemberInfo.)
Public property DeclaringType Gets the class that declares this member. (Inherited from MemberInfo.)
Public property FieldHandle Gets a RuntimeFieldHandle, which is a handle to the internal metadata representation of a field.
Public property FieldType Gets the type of this field object.
Public property IsAssembly Gets a value indicating whether the potential visibility of this field is described by 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.
Public property IsFamily Gets a value indicating whether the visibility of this field is described by FieldAttributes.Family; that is, the field is visible only within its class and derived classes.
Public property IsFamilyAndAssembly Gets a value indicating whether the visibility of this field is described by FieldAttributes.FamANDAssem; that is, the field can be accessed from derived classes, but only if they are in the same assembly.
Public property IsFamilyOrAssembly Gets a value indicating whether the potential visibility of this field is described by FieldAttributes.FamORAssem; that is, the field can be accessed by derived classes wherever they are, and by classes in the same assembly.
Public property IsInitOnly Gets a value indicating whether the field can only be set in the body of the constructor.
Public property IsLiteral Gets a value indicating whether the value is written at compile time and cannot be changed.
Public property IsNotSerialized Gets a value indicating whether this field has the NotSerialized attribute.
Public property IsPinvokeImpl Gets a value indicating whether the corresponding PinvokeImpl attribute is set in FieldAttributes.
Public property IsPrivate Gets a value indicating whether the field is private.
Public property IsPublic Gets a value indicating whether the field is public.
Public property IsSecurityCritical Gets a value that indicates whether the current field is security-critical or security-safe-critical at the current trust level.
Public property IsSecuritySafeCritical Gets a value that indicates whether the current field is security-safe-critical at the current trust level.
Public property IsSecurityTransparent Gets a value that indicates whether the current field is transparent at the current trust level.
Public property IsSpecialName Gets a value indicating whether the corresponding SpecialName attribute is set in the FieldAttributes enumerator.
Public property IsStatic Gets a value indicating whether the field is static.
Public property MemberType Gets a MemberTypes value indicating that this member is a field. (Overrides MemberInfo.MemberType.)
Public property MetadataToken Gets a value that identifies a metadata element. (Inherited from MemberInfo.)
Public property Module Gets the module in which the type that declares the member represented by the current MemberInfo is defined. (Inherited from MemberInfo.)
Public property Name Gets the name of the current member. (Inherited from MemberInfo.)
Public property ReflectedType Gets the class object that was used to obtain this instance of MemberInfo. (Inherited from MemberInfo.)
Top
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft