views:

47

answers:

1

If I extend a standard Java Class and make the subclass a Seam component, are the inherited methods going to have the overhead of interception?

In other words, do I have to Override them and annotate them with @BypassInterceptors?

+1  A: 

Short answer: Yep they will be intercepted.

When you make a component, all calls will be intercepted.

When you use @In or Component.getInstance what you get is a proxy to the object, not the object itself, it's in the proxy that the interception magic occurs.

If you are really worried about the performance the best bet would be to mark the subclass with @BypassInterceptors and use Component.getInstance(...)

tiago