db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t...@apache.org
Subject cvs commit: db-ojb release-notes.txt
Date Tue, 03 Jun 2003 19:33:18 GMT
thma        2003/06/03 12:33:18

  Modified:    src/java/org/apache/ojb/broker/query QueryByCriteria.java
               .        release-notes.txt
  Log:
  add new convenience constructor to QueryByCriteria to
  allow easy construction of extent queries
  
  Revision  Changes    Path
  1.16      +17 -1     db-ojb/src/java/org/apache/ojb/broker/query/QueryByCriteria.java
  
  Index: QueryByCriteria.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/broker/query/QueryByCriteria.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- QueryByCriteria.java	13 May 2003 15:23:29 -0000	1.15
  +++ QueryByCriteria.java	3 Jun 2003 19:33:18 -0000	1.16
  @@ -99,6 +99,12 @@
       private List m_prefetchedRelationships = null;
       
       private Map m_pathOuterJoin;
  +    
  +    /**
  +     * handy criteria that can be used to select all instances of 
  +     * a class.
  +     */
  +    public static final Criteria CRITERIA_SELECT_ALL = null;
   
       /**
        * Build a Query for class targetClass with criteria.
  @@ -170,6 +176,16 @@
           this(anObject.getClass(), buildCriteria(anObject));
       }
   
  +    /**
  +     * Build a Query based on a Class Object. This
  +     * Query will return all instances of the given class.
  +     * @param aClassToSearchFrom the class to search from
  +     * @return a QueryByCriteria returning all instances of aClassToSearchFrom
  +     */
  +    public QueryByCriteria(Class aClassToSearchFrom)
  +    {
  +        this(aClassToSearchFrom, CRITERIA_SELECT_ALL);
  +    }
   
       /**
        * Build Criteria based on example object<br>
  
  
  
  1.14      +6 -1      db-ojb/release-notes.txt
  
  Index: release-notes.txt
  ===================================================================
  RCS file: /home/cvs/db-ojb/release-notes.txt,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- release-notes.txt	28 May 2003 09:00:47 -0000	1.13
  +++ release-notes.txt	3 Jun 2003 19:33:18 -0000	1.14
  @@ -14,7 +14,8 @@
   NEW FEATURES:
   - With this release we are feature complete for the 1.0 release!
   For 1.0 you should not expect more features to be added.
  -
  +- added a XDoclet OJB Module that allows to generate repository.xml
  +  and DDL from tagged Java sources to the "contrib" distribution.
   
   NOTES:
   - update used xdoclet version in 'ejb-examples'
  @@ -26,6 +27,10 @@
   of different persistent object metadata profiles (means different
   org.apache.ojb.broker.metadata.DescriptorRepository instances) at
   runtime
  +- Provide a PUBLIC doctype declaration for the repository.xml
  +- add a convenience Constructor to QueryByCriteria that
  +  builds a query selecting all instances of a class
  +
   
   BUG FIXES:
   - fix several bugs in documentation
  
  
  

Mime
View raw message