c# - Is there any way to get the instance class inside the attribute code? -


Is there a way to get an instance class inside the attribute codename C #?

  Public class MyAttirbute: attribute {public someMethod () {this.InstanceClass ???? }}  

No, unfortunately not.

Attributes are types and per members (such as per "some" which they are attached), not for example

You can also inspect the properties and those methods can be called without any examples of that class have been implemented to do this.

What are you trying to do that need this?


Comments

Popular posts from this blog

paypal - How to know the URL referrer in PHP? -

oauth - Facebook OAuth2 Logout does not remove fb_ cookie -

wpf - Line breaks and indenting for the XAML of a saved FlowDocument? -