User: danch   
  Date: 01/05/26 17:49:15

  Modified:    src/main/org/jboss/ejb/plugins/jaws
                        JAWSPersistenceManager.java JPMCommandFactory.java
                        JPMFindEntitiesCommand.java
  Added:       src/main/org/jboss/ejb/plugins/jaws
                        JPMLoadEntitiesCommand.java
  Log:
  added 'read-ahead' option for finders in JAWS
  
  Revision  Changes    Path
  1.27      +14 -2     
jboss/src/main/org/jboss/ejb/plugins/jaws/JAWSPersistenceManager.java
  
  Index: JAWSPersistenceManager.java
  ===================================================================
  RCS file: 
/cvsroot/jboss/jboss/src/main/org/jboss/ejb/plugins/jaws/JAWSPersistenceManager.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -r1.26 -r1.27
  --- JAWSPersistenceManager.java       2000/12/07 18:16:10     1.26
  +++ JAWSPersistenceManager.java       2001/05/27 00:49:15     1.27
  @@ -11,6 +11,7 @@
   import java.rmi.RemoteException;
   
   import java.util.Collection;
  +import java.util.Map;
   
   import javax.ejb.CreateException;
   import javax.ejb.DuplicateKeyException;
  @@ -25,16 +26,18 @@
   import org.jboss.ejb.plugins.jaws.jdbc.JDBCCommandFactory;
   
   import org.jboss.logging.Log;
  +import org.jboss.util.FinderResults;
   
   /**
    *   Just Another Web Store - an O/R mapper
    *
    * @see org.jboss.ejb.EntityPersistenceStore
  + * @author <a href="mailto:[EMAIL PROTECTED]";>danch (Dan Christopherson)</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Rickard �berg</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Marc Fleury</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Joe Shevland</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Justin Forder</a>
  - * @version $Revision: 1.26 $
  + * @version $Revision: 1.27 $
    */
   public class JAWSPersistenceManager
      implements EntityPersistenceStore
  @@ -55,10 +58,12 @@
      JPMCreateEntityCommand createEntityCommand;
      JPMRemoveEntityCommand removeEntityCommand;
      JPMLoadEntityCommand loadEntityCommand;
  +   JPMLoadEntitiesCommand loadEntitiesCommand;
      JPMStoreEntityCommand storeEntityCommand;
   
      JPMActivateEntityCommand activateEntityCommand;
      JPMPassivateEntityCommand passivateEntityCommand;
  +   
   
      Log log = Log.createLog("JAWS");
   
  @@ -87,6 +92,7 @@
         createEntityCommand = commandFactory.createCreateEntityCommand();
         removeEntityCommand = commandFactory.createRemoveEntityCommand();
         loadEntityCommand = commandFactory.createLoadEntityCommand();
  +      loadEntitiesCommand = commandFactory.createLoadEntitiesCommand();
         storeEntityCommand = commandFactory.createStoreEntityCommand();
   
         activateEntityCommand = commandFactory.createActivateEntityCommand();
  @@ -130,7 +136,7 @@
         return findEntityCommand.execute(finderMethod, args, ctx);
      }
   
  -   public Collection findEntities(Method finderMethod,
  +   public FinderResults findEntities(Method finderMethod,
                                     Object[] args,
                                     EntityEnterpriseContext ctx)
         throws RemoteException, FinderException
  @@ -148,6 +154,12 @@
         throws RemoteException
      {
         loadEntityCommand.execute(ctx);
  +   }
  +   
  +   public void loadEntities(FinderResults keys) 
  +      throws RemoteException
  +   {
  +      loadEntitiesCommand.execute(keys);
      }
   
      public void storeEntity(EntityEnterpriseContext ctx)
  
  
  
  1.3       +3 -1      jboss/src/main/org/jboss/ejb/plugins/jaws/JPMCommandFactory.java
  
  Index: JPMCommandFactory.java
  ===================================================================
  RCS file: 
/cvsroot/jboss/jboss/src/main/org/jboss/ejb/plugins/jaws/JPMCommandFactory.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- JPMCommandFactory.java    2000/12/07 15:44:29     1.2
  +++ JPMCommandFactory.java    2001/05/27 00:49:15     1.3
  @@ -10,7 +10,7 @@
    * Interface for JAWSPersistenceManager Command Factories 
    *    
    * @author <a href="mailto:[EMAIL PROTECTED]";>Justin Forder</a>
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
   public interface JPMCommandFactory
   {
  @@ -37,6 +37,8 @@
      public JPMRemoveEntityCommand createRemoveEntityCommand();
      
      public JPMLoadEntityCommand createLoadEntityCommand();
  +   
  +   public JPMLoadEntitiesCommand createLoadEntitiesCommand();
      
      public JPMStoreEntityCommand createStoreEntityCommand();
      
  
  
  
  1.3       +3 -2      
jboss/src/main/org/jboss/ejb/plugins/jaws/JPMFindEntitiesCommand.java
  
  Index: JPMFindEntitiesCommand.java
  ===================================================================
  RCS file: 
/cvsroot/jboss/jboss/src/main/org/jboss/ejb/plugins/jaws/JPMFindEntitiesCommand.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- JPMFindEntitiesCommand.java       2000/12/07 15:44:30     1.2
  +++ JPMFindEntitiesCommand.java       2001/05/27 00:49:15     1.3
  @@ -12,18 +12,19 @@
   import org.jboss.ejb.EntityEnterpriseContext;
   import java.rmi.RemoteException;
   import javax.ejb.FinderException;
  +import org.jboss.util.FinderResults;
   
   /**
    * Interface for JAWSPersistenceManager FindEntities Command.
    *      
    * @author <a href="mailto:[EMAIL PROTECTED]";>Justin Forder</a>
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
   public interface JPMFindEntitiesCommand
   {
      // Public --------------------------------------------------------
      
  -   public Collection execute(Method finderMethod, 
  +   public FinderResults execute(Method finderMethod, 
                                Object[] args, 
                                EntityEnterpriseContext ctx)
         throws RemoteException, FinderException;
  
  
  
  1.1                  
jboss/src/main/org/jboss/ejb/plugins/jaws/JPMLoadEntitiesCommand.java
  
  Index: JPMLoadEntitiesCommand.java
  ===================================================================
  /*
   * JBoss, the OpenSource EJB server
   *
   * Distributable under LGPL license.
   * See terms of license at gnu.org.
   */
   
  package org.jboss.ejb.plugins.jaws;
  
  import java.rmi.RemoteException;
  import java.util.Map;
  import org.jboss.util.FinderResults;
  import org.jboss.ejb.plugins.jaws.metadata.PkFieldMetaData;
  
  /**
   * Interface for JAWSPersistenceManager LoadEntities
   *      
   * @author <a href="mailto:[EMAIL PROTECTED]";>danch (Dan Christopherson)</a>
   * @version $Revision: 1.1 $
   */
  public interface JPMLoadEntitiesCommand
  {
     // Public --------------------------------------------------------
     
     public void execute(FinderResults keys)
        throws RemoteException;
  }
  
  
  
  

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to