db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From arm...@apache.org
Subject cvs commit: db-ojb/src/java/org/apache/ojb/broker/util BrokerHelper.java
Date Thu, 11 Nov 2004 23:48:26 GMT
arminw      2004/11/11 15:48:26

  Modified:    src/java/org/apache/ojb/broker/util BrokerHelper.java
  Log:
  add proxy check to get real class
  
  Revision  Changes    Path
  1.69      +4 -5      db-ojb/src/java/org/apache/ojb/broker/util/BrokerHelper.java
  
  Index: BrokerHelper.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/broker/util/BrokerHelper.java,v
  retrieving revision 1.68
  retrieving revision 1.69
  diff -u -r1.68 -r1.69
  --- BrokerHelper.java	17 Oct 2004 15:19:38 -0000	1.68
  +++ BrokerHelper.java	11 Nov 2004 23:48:26 -0000	1.69
  @@ -134,16 +134,15 @@
       private ClassDescriptor getRealClassDescriptor(ClassDescriptor aCld, Object anObj)
       {
           ClassDescriptor result;
  -
  -        if(aCld.getClassOfObject() == anObj.getClass())
  +        Class realClass = ProxyHelper.getRealClass(anObj);
  +        if(aCld.getClassOfObject() == realClass)
           {
               result = aCld;
           }
           else
           {
  -            result = aCld.getRepository().getDescriptorFor(anObj.getClass());
  +            result = aCld.getRepository().getDescriptorFor(realClass);
           }
  -
           return result;
       }
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Mime
View raw message