Announcement Announcement Module
No announcement yet.
Referencing autoproxied target Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Referencing autoproxied target

    A user in the webforum ( was wondering whether or not it's possible to reference or reach a proxied object creating by an AutoProxyCreator (so not hte proxy, but target itself).

    The FactoryBean has support for reaching the factorybean itself instead of objects it creates (prefix an ampersand). Wouldn't it be a nice features to allow autoproxied objects to referenced the same way?

    Rod, anyone, opinions?
    Last edited by robyn; May 14th, 2006, 04:49 PM.

  • #2
    Programmatically you can cast the reference to Advised and get the target source from there. If it's a simple target, it will be of type SingletonTargetSource.

    The problem with a mechanism like the ampersand is that it wouldn't work for dynamic target sources, which may return a different target instance on each invocation.