PostSharp6.6//API Reference/Post­Sharp.​Aspects.​Advices Namespace/Import­Location­Advice­Instance Class/Import­Location­Advice­Instance Constructor/Import­Location­Advice­Instance Constructor (Field­Info, Location­Info)

ImportLocationAdviceInstance Constructor (FieldInfo, LocationInfo)

Initializes a new instance of the ImportLocationAdviceInstance class and specifies which field or property should be imported by giving its reflection representation.

Namespace:  PostSharp.Aspects.Advices
Assembly:  PostSharp (in PostSharp.dll) Version: 6.6.7.0 (6.6.7.0)
Syntax
C#
public ImportLocationAdviceInstance(
	FieldInfo aspectField,
	LocationInfo location
)

Parameters

aspectField
Type: System.Reflection.FieldInfo
A field of the aspect class to which location should be bound at runtime. This field can be of type ILocationBinding, Property<TValue>, or a type that is both (a) derived from ICollection<ILocationBinding> and (b) has a parameterless constructor.
location
Type: PostSharp.Reflection.LocationInfo
The field or property to import.
See Also