forked from reflection-emit/Cauldron
-
Notifications
You must be signed in to change notification settings - Fork 18
Open
Description
Hi all,
I could not find the information in the wiki so I'm asking here.
I created a small Property Attribute to intercept Properties :
[AttributeUsage(AttributeTargets.Property)]
public sealed class ViewContextAttribute : Attribute, IPropertyInterceptor, IPropertyInterceptorInitialize, IMethodInterceptor, IMethodInterceptorOnExit
{
[AssignMethod("Get{Name}", true)]
public Func<bool> _onGetProperty;
...
}When it complies, everything works fine, but I was wondering if when the AssignMethod is found, it could wrap it with the MethodInterceptor functionalities?
[ViewContext()]
public bool IsDraggingEnabled => GetIsDraggingEnabled();In other words, I want to override the return value of IsDraggingEnabled but never loose the actual value of GetIsDraggingEnabled();
Is it something possible?
Thanks for your help.
Simon
LaborJos
Metadata
Metadata
Assignees
Labels
No labels