You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by sk...@apache.org on 2008/02/22 10:58:38 UTC
svn commit: r630134 -
/myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/conversation/spring/_SpringUtils.java
Author: skitching
Date: Fri Feb 22 01:58:36 2008
New Revision: 630134
URL: http://svn.apache.org/viewvc?rev=630134&view=rev
Log:
Add docs only
Modified:
myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/conversation/spring/_SpringUtils.java
Modified: myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/conversation/spring/_SpringUtils.java
URL: http://svn.apache.org/viewvc/myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/conversation/spring/_SpringUtils.java?rev=630134&r1=630133&r2=630134&view=diff
==============================================================================
--- myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/conversation/spring/_SpringUtils.java (original)
+++ myfaces/orchestra/trunk/core/src/main/java/org/apache/myfaces/orchestra/conversation/spring/_SpringUtils.java Fri Feb 22 01:58:36 2008
@@ -184,6 +184,10 @@
* of Orchestra but at the current time it is not known whether this functionality can
* be implemented for all dependency-injection frameworks. If it does, then it might
* later make sense to promote this up to the public Orchestra API.
+ * <p>
+ * Note that invoking this method will create the "real bean" if it does not yet exist.
+ * There is currently no way of testing whether this will happen, ie null will never
+ * be returned from this method.
*/
public static Object getRealBean(Object proxy) throws Exception
{
@@ -191,6 +195,11 @@
TargetSource targetSource = advised.getTargetSource();
Object real = targetSource.getTarget();
+ // Possibly we could add a method on the ScopedBeanTargetSource class to test
+ // whether the target bean exists. Then here we could cast TargetSource to
+ // ScopedBeanTargetSource and return null if the target does not exist. This
+ // might be useful, but let's leave that until someone actually has a use-case
+ // for that functionality.
return real;
}
}