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/odmg ImplementationExt.java ImplementationImpl.java NarrowTransaction.java OJB.java TransactionExt.java TransactionImpl.java
Date Wed, 23 Mar 2005 16:56:29 GMT
arminw      2005/03/23 08:56:29

  Modified:    src/java/org/apache/ojb/odmg/oql Tag: OJB_1_0_RELEASE
                        EnhancedOQLQuery.java
               src/java/org/apache/ojb/odmg Tag: OJB_1_0_RELEASE
                        ImplementationImpl.java NarrowTransaction.java
                        OJB.java TransactionExt.java TransactionImpl.java
  Added:       src/java/org/apache/ojb/odmg Tag: OJB_1_0_RELEASE
                        ImplementationExt.java
  Log:
  encapsulate extensions of the Implementation interface in ImplementationExt
  update javadoc
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.5.2.1   +23 -3     db-ojb/src/java/org/apache/ojb/odmg/oql/EnhancedOQLQuery.java
  
  Index: EnhancedOQLQuery.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/odmg/oql/EnhancedOQLQuery.java,v
  retrieving revision 1.5
  retrieving revision 1.5.2.1
  diff -u -r1.5 -r1.5.2.1
  --- EnhancedOQLQuery.java	4 Apr 2004 23:53:40 -0000	1.5
  +++ EnhancedOQLQuery.java	23 Mar 2005 16:56:29 -0000	1.5.2.1
  @@ -18,13 +18,33 @@
   import org.odmg.OQLQuery;
   import org.odmg.QueryInvalidException;
   
  +/**
  + * Offers useful none odmg-standard methods of the odmg {@link org.odmg.OQLQuery} interface.
  + * <p>
  + * Note: All listed methods are <strong>not</strong> part of the standard ODMG-api
-
  + * they are special (proprietary) OJB extensions.
  + * </p>
  + *
  + * @version $Id$
  + */
   public interface EnhancedOQLQuery extends OQLQuery
   {
  -	void create(String queryString, int startAtIndex, int endAtIndex) throws QueryInvalidException;
  +	/**
  +     * An extension of the {@link org.odmg.OQLQuery#create(String)} method, which
  +     * additionally allow to specify an <em>start-</em> and <em>end-Index</em>
for
  +     * the query.
  +     *
  +     * @param queryString An oql query string.
  +     * @param startAtIndex The start index.
  +     * @param endAtIndex The end index.
  +     * @throws QueryInvalidException The type of the parameter does
  +     * not correspond with the type of the parameter in the query.
  +     */
  +    void create(String queryString, int startAtIndex, int endAtIndex) throws QueryInvalidException;
   	
       /**
  -     * @deprecated 
  -     * @return
  +     * Deprecated method.
  +     * @deprecated
        */
       int fullSize();
   }
  
  
  
  No                   revision
  No                   revision
  1.1.2.6   +29 -6     db-ojb/src/java/org/apache/ojb/odmg/ImplementationImpl.java
  
  Index: ImplementationImpl.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/odmg/ImplementationImpl.java,v
  retrieving revision 1.1.2.5
  retrieving revision 1.1.2.6
  diff -u -r1.1.2.5 -r1.1.2.6
  --- ImplementationImpl.java	22 Mar 2005 17:08:37 -0000	1.1.2.5
  +++ ImplementationImpl.java	23 Mar 2005 16:56:29 -0000	1.1.2.6
  @@ -54,7 +54,7 @@
    *
    * @version $Id$
    */
  -public class ImplementationImpl extends Object implements Implementation
  +public class ImplementationImpl extends Object implements ImplementationExt
   {
       private Logger log = LoggerFactory.getLogger(ImplementationImpl.class);
   
  @@ -342,6 +342,8 @@
        * turning of implicit locking may improve performance but requires
        * additional care to make sure all changed objects are properly
        * registered to the transaction.
  +     *
  +     * @deprecated use {@link TransactionExt#setImplicitLocking(boolean)} instead.
        * @param value if set to true implicit locking is enabled,
        *        if false, implicit locking is disabled.
        **/
  @@ -350,23 +352,44 @@
   		((TransactionExt)currentTransaction()).setImplicitLocking(value);
   	}
   
  +    /**
  +     * @deprecated use {@link TransactionExt#isImplicitLocking()} instead.
  +     * @return
  +     */
  +    boolean isImplicitLocking()
  +    {
  +        return implicitLocking;
  +    }
  +
  +    /**
  +     * @see ImplementationExt#getOqlCollectionClass()
  +     */
       public Class getOqlCollectionClass()
       {
           return oqlCollectionClass;
       }
   
  +    /**
  +     * @see ImplementationExt#setOqlCollectionClass(Class)
  +     */
       public void setOqlCollectionClass(Class oqlCollectionClass)
       {
           this.oqlCollectionClass = oqlCollectionClass;
       }
   
  -    boolean isImpliciteWriteLocks()
  +    /**
  +     * @see ImplementationExt#setImpliciteWriteLocks(boolean)
  +     */
  +    public void setImpliciteWriteLocks(boolean impliciteWriteLocks)
       {
  -        return impliciteWriteLocks;
  +        this.impliciteWriteLocks = impliciteWriteLocks;
       }
   
  -    boolean isImplicitLocking()
  +    /**
  +     * @see ImplementationExt#isImpliciteWriteLocks()
  +     */
  +    public boolean isImpliciteWriteLocks()
       {
  -        return implicitLocking;
  +        return impliciteWriteLocks;
       }
   }
  
  
  
  1.10.2.4  +14 -0     db-ojb/src/java/org/apache/ojb/odmg/NarrowTransaction.java
  
  Index: NarrowTransaction.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/odmg/NarrowTransaction.java,v
  retrieving revision 1.10.2.3
  retrieving revision 1.10.2.4
  diff -u -r1.10.2.3 -r1.10.2.4
  --- NarrowTransaction.java	22 Mar 2005 17:08:37 -0000	1.10.2.3
  +++ NarrowTransaction.java	23 Mar 2005 16:56:29 -0000	1.10.2.4
  @@ -151,11 +151,25 @@
       	tx.setImplicitLocking(value);
       }
   
  +    /**
  +     * @see org.apache.ojb.odmg.TransactionExt#isImplicitLocking
  +     */
  +    public boolean isImplicitLocking()
  +    {
  +        return tx.isImplicitLocking();
  +    }
  +
  +    /**
  +     * @see org.apache.ojb.odmg.TransactionExt#setCascadingDelete(Class, String, boolean)
  +     */
       public void setCascadingDelete(Class target, String referenceField, boolean doCascade)
       {
           tx.setCascadingDelete(target, referenceField, doCascade);
       }
   
  +    /**
  +     * @see org.apache.ojb.odmg.TransactionExt#setCascadingDelete(Class, boolean) 
  +     */
       public void setCascadingDelete(Class target, boolean doCascade)
       {
           tx.setCascadingDelete(target, doCascade);
  
  
  
  1.17.2.1  +3 -3      db-ojb/src/java/org/apache/ojb/odmg/OJB.java
  
  Index: OJB.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/odmg/OJB.java,v
  retrieving revision 1.17
  retrieving revision 1.17.2.1
  diff -u -r1.17 -r1.17.2.1
  --- OJB.java	3 May 2004 23:05:56 -0000	1.17
  +++ OJB.java	23 Mar 2005 16:56:29 -0000	1.17.2.1
  @@ -47,9 +47,9 @@
        * Return new instance of the {@link org.odmg.Implementation} class.
        * The used implementation class can be specified in OJB properties file.
        */
  -    public static Implementation getInstance()
  +    public static ImplementationExt getInstance()
       {
  -        return (Implementation) instance.createNewInstance();
  +        return (ImplementationExt) instance.createNewInstance();
       }
   
       protected String getConfigurationKey()
  
  
  
  1.4.2.3   +10 -6     db-ojb/src/java/org/apache/ojb/odmg/TransactionExt.java
  
  Index: TransactionExt.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/odmg/TransactionExt.java,v
  retrieving revision 1.4.2.2
  retrieving revision 1.4.2.3
  diff -u -r1.4.2.2 -r1.4.2.3
  --- TransactionExt.java	23 Mar 2005 15:12:49 -0000	1.4.2.2
  +++ TransactionExt.java	23 Mar 2005 16:56:29 -0000	1.4.2.3
  @@ -18,11 +18,11 @@
    */
   
   /**
  - * Offers useful none odmg-standard methods.
  + * Offers useful none odmg-standard methods of the odmg {@link org.odmg.Transaction} interface.
    * <p>
  - * Note: All listed methods are <b>not</b> part of the standard ODMG-api -
  + * Note: All listed methods are <strong>not</strong> part of the standard ODMG-api
-
    * they are special (proprietary) OJB extensions.
  - * <p/>
  + * </p>
    *
    * @version $Id$
    */
  @@ -57,8 +57,7 @@
        * This method is very similair to {@link org.odmg.Transaction#checkpoint}.
        */
       public void flush();
  -    
  -    
  +
       /**
        * This method can be used to activate or deactivate the implicit
        * locking mechanism for the current transaction.
  @@ -72,6 +71,11 @@
       public void setImplicitLocking(boolean value);
   
       /**
  +     * Returns <em>true</em> if implicite locking is enabled.
  +     */
  +    public boolean isImplicitLocking();
  +
  +    /**
        * Allows to change the <em>cascading delete</em> behavior of the target
class's
        * reference field while this transaction is in use.
        *
  
  
  
  1.59.2.12 +6 -1      db-ojb/src/java/org/apache/ojb/odmg/TransactionImpl.java
  
  Index: TransactionImpl.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/odmg/TransactionImpl.java,v
  retrieving revision 1.59.2.11
  retrieving revision 1.59.2.12
  diff -u -r1.59.2.11 -r1.59.2.12
  --- TransactionImpl.java	23 Mar 2005 12:32:15 -0000	1.59.2.11
  +++ TransactionImpl.java	23 Mar 2005 16:56:29 -0000	1.59.2.12
  @@ -1187,6 +1187,11 @@
           implicitLocking = value;
       }
   
  +    public boolean isImplicitLocking()
  +    {
  +        return implicitLocking;
  +    }
  +
       /**
        * noop -- here for interface
        */
  
  
  
  No                   revision
  
  Index: TransactionImpl.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/odmg/TransactionImpl.java,v
  retrieving revision 1.59.2.11
  retrieving revision 1.59.2.12
  diff -u -r1.59.2.11 -r1.59.2.12
  --- TransactionImpl.java	23 Mar 2005 12:32:15 -0000	1.59.2.11
  +++ TransactionImpl.java	23 Mar 2005 16:56:29 -0000	1.59.2.12
  @@ -1187,6 +1187,11 @@
           implicitLocking = value;
       }
   
  +    public boolean isImplicitLocking()
  +    {
  +        return implicitLocking;
  +    }
  +
       /**
        * noop -- here for interface
        */
  
  
  
  No                   revision
  
  Index: TransactionImpl.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/odmg/TransactionImpl.java,v
  retrieving revision 1.59.2.11
  retrieving revision 1.59.2.12
  diff -u -r1.59.2.11 -r1.59.2.12
  --- TransactionImpl.java	23 Mar 2005 12:32:15 -0000	1.59.2.11
  +++ TransactionImpl.java	23 Mar 2005 16:56:29 -0000	1.59.2.12
  @@ -1187,6 +1187,11 @@
           implicitLocking = value;
       }
   
  +    public boolean isImplicitLocking()
  +    {
  +        return implicitLocking;
  +    }
  +
       /**
        * noop -- here for interface
        */
  
  
  
  1.1.2.1   +71 -0     db-ojb/src/java/org/apache/ojb/odmg/Attic/ImplementationExt.java
  
  
  
  

---------------------------------------------------------------------
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