PostSharp SDK 2023.0 / / Class Reference / Post­Sharp.​Sdk.​Code­Model Namespace / Field­Ref­Declaration Class / Field­Ref­Declaration Methods

FieldRefDeclaration Methods

The FieldRefDeclaration type exposes the following members.

Methods
  NameDescription
Public methodClearCache
Clear the cache (typically mapping to System.Reflection or, if the current element is a reference, to the related definition) of the current Element and all its children.
(Overrides Element.ClearCache().)
Public methodDispose Obsolete. (Inherited from MetadataDeclaration.)
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodGetFieldDefinition()
Finds in the current domain the FieldDefDeclaration corresponding to the current field with default BindingOptions.
Public methodGetFieldDefinition(BindingOptions)
Finds in the current domain the FieldDefDeclaration corresponding to the current field and specifies BindingOptions.
Public methodGetGenericContext
Gets the generic context of the declaring type, or an empty context if the member is contained by the module.
Public methodGetGenericInstance
Gets a generic instance of the current field.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetSystemField(Type[], Type[])
Public methodGetSystemField(Type[], Type[], BindingOptions)
Gets the system runtime field corresponding to the current field.
Public methodGetTag<T>
Gets a tag associated with the current declaration.
(Inherited from MetadataDeclaration.)
Public methodGetTokenType
Gets the TokenType of the derived declaration.
(Inherited from MemberRefDeclaration.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodSetTag<T>
Set a tag to the current declaration.
(Inherited from MetadataDeclaration.)
Public methodToString (Overrides NamedMetadataDeclaration.ToString().)
Public methodTranslate
Extension Methods
  NameDescription
Public Extension MethodGetDisplayName
Gets the name of a given declaration as it should be displayed to the user.
(Defined by WriteReflectionNameExtensions.)
Public Extension MethodGetReflectionName()Overloaded.
Gets the name of a given declaration and returns a string that is compatible with the result of the ToString method of system reflection objects.
(Defined by WriteReflectionNameExtensions.)
Public Extension MethodGetReflectionName(ReflectionNameOptions)Overloaded.
Gets the name of a given declaration and returns a string that is compatible with the result of the ToString method of system reflection objects.
(Defined by WriteReflectionNameExtensions.)
Public Extension MethodGetReflectionName(ReflectionNameOptions, NameMapper)Overloaded.
Gets the name of a given declaration, constructed using given options.
(Defined by WriteReflectionNameExtensions.)
Public Extension MethodIsExternallyVisible
Determines whether a member is visible outside its assembly.
(Defined by VisibilityHelper.)
Public Extension MethodIsPublic
Determines whether a member is visible outside its assembly.
(Defined by VisibilityHelper.)
Public Extension MethodIsVisible
Determines whether a member is visible from a given scope.
(Defined by VisibilityHelper.)
See Also