zonghaishang commented on a change in pull request #1511: Add feature:require 
Reference service dynamically
URL: https://github.com/apache/incubator-dubbo/pull/1511#discussion_r179516001
 
 

 ##########
 File path: 
dubbo-config/dubbo-config-spring/src/main/java/com/alibaba/dubbo/config/spring/AnnotationBean.java
 ##########
 @@ -288,6 +296,73 @@ private Object refer(Reference reference, Class<?> 
referenceClass) { //method.ge
         return referenceConfig.get();
     }
 
+    /**
+     * refer 方法的公开版,将注解参数Reference换为 ReferenceConf 类
+     * @param reference
+     * @param referenceClass
+     * @return
+     */
+    public Object referNew(RefConf reference, Class<?> referenceClass) { 
//method.getParameterTypes()[0]
+        String interfaceName;
+
+        if (! "".equals( reference.interfaceName)) {
 
 Review comment:
   @zhouzhipeng Existing refer methods is private, you can rename refer to 
refer0,  I think use refer better than referNew.  Of course, it's all depends 
on you, thank you very much for your contribution.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to