Imagine a simple attrbute class. The attribute has been used on a property.
Can the Attribute Class "see" where it has been applied?
[AttributeUsage(AttributeTargets.Property)]
public class MyPropAttr : Attribute {
public MyPropAttr () {
PropName = ????; // default I was applied to prop X
}
public string SomeAttribute { get; set; }
public string PropName { get; set; } //<<<<<<<<< can this be determined ???
}
public class MyClass{
[MyPropAttr(SomeAttribute="Bla")]
public string SomeFancyProp{ get; set; }
}