db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Leandro Rodrigo Saad Cruz <lean...@ibnetwork.com.br>
Subject [FYI] more than one hint class for path expression
Date Tue, 13 May 2003 15:30:52 GMT
Hi all. You can now use more than one hint class for path expressions.
Example.

<java>

Criteria crit = new Criteria();
crit.addEqualTo("path.field",someValue);
QueryByCriteria query = new QueryByCriteria(Clazz.class,crit);
query.addPathClass(HintAbstractClass.class);
query.addPathClass(HintOne.class);
query.addPathClass(HintTwo.class);

Collection result = broker.getCollectionByQuery(query);

</java>

The code above retrieves a List of Clazz objects that have an
aggregation to HintAbstractClass denoted by path. Only subclasses
HintOne and HintTwo will be used onto  the join .

HintOne and HintTwo must be part of the HintAbstractClass extent.

If no path class is provided all extent classes will be used on the
join.

-- 
Leandro Rodrigo Saad Cruz
IT - Inter Business Tecnologia e Servicos (IB)
http://www.ibnetwork.com.br
http://jakarta.apache.org/ojb


Mime
View raw message