dlr         01/08/13 15:31:06

  Modified:    src/java/org/apache/torque/map DatabaseMap.java
  Log:
  Cleanup and updates in light of API changes.
  
  Revision  Changes    Path
  1.3       +9 -6      
jakarta-turbine-torque/src/java/org/apache/torque/map/DatabaseMap.java
  
  Index: DatabaseMap.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-turbine-torque/src/java/org/apache/torque/map/DatabaseMap.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -u -r1.2 -r1.3
  --- DatabaseMap.java  2001/08/10 12:23:02     1.2
  +++ DatabaseMap.java  2001/08/13 22:31:06     1.3
  @@ -57,6 +57,7 @@
   import java.util.Enumeration;
   import java.util.HashMap;
   import java.util.Hashtable;
  +import org.apache.torque.adapter.IDMethod;
   import org.apache.torque.oid.IDBroker;
   import org.apache.torque.oid.IdGenerator;
   
  @@ -64,7 +65,8 @@
    * DatabaseMap is used to model a database.
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>John D. McNally</a>
  - * @version $Id: DatabaseMap.java,v 1.2 2001/08/10 12:23:02 knielsen Exp $
  + * @author <a href="mailto:[EMAIL PROTECTED]";>Daniel Rall</a>
  + * @version $Id: DatabaseMap.java,v 1.3 2001/08/13 22:31:06 dlr Exp $
    */
   public class DatabaseMap
   {
  @@ -82,6 +84,8 @@
   
       /** The IDBroker that goes with the idTable. */
       private IDBroker idBroker = null;
  +
  +    /** The IdGenerators, keyed by type of idMethod. */
       private HashMap idGenerators;
   
       /**
  @@ -97,8 +101,7 @@
        * @param name Name of the database.
        * @param numberOfTables Number of tables in the database.
        */
  -    public DatabaseMap( String name,
  -                        int numberOfTables )
  +    public DatabaseMap(String name, int numberOfTables)
       {
           this.name = name;
           tables = new Hashtable( (int)(1.25*numberOfTables) + 1 );
  @@ -248,7 +251,7 @@
           this.idTable = idTable;
           addTable(idTable);
           idBroker = new IDBroker(idTable);
  -        addIdGenerator(TableMap.IDBROKERTABLE, idBroker);
  +        addIdGenerator(IDMethod.ID_BROKER, idBroker);
       }
   
       /**
  @@ -274,8 +277,8 @@
       }
   
       /**
  -     * Get a type of id generator. Example valid values are:
  -     * TableMap.IDBROKERTABLE, TableMap.AUTOINCREMENT, TableMap.SEQUENCE
  +     * Get a type of id generator.  Valid values are listed in the
  +     * {@link org.apache.torque.adapter.IDMethod} interface.
        *
        * @param type a <code>String</code> value
        * @return an <code>IdGenerator</code> value
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to