views:

61

answers:

1

Using PIAB / Unity, is it possible to intercept "child" method calls ?

e.g. the class has three methods ...

DoSomething(), DoFirst(), DoSecond()

The DoSomething() method calls DoFirst() which in turn calls DoSecond()

I can get interception of DoSomething, but I can't get anything for DoFirst and DoSecond. I've tried various of the Policy Injection rules ... Type Matching, Tag Attribute, Method Signature ... but nothing works. But I can intercept each method if I call them directly

So basic question ... can you even do this ?

And if so, how !!

+1  A: 

I've found that I need to use the VirtualMethodInterceptor rather than the TransparentProxy or Interception interceptors

SteveC