jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alarcher <antoinelarc...@gmail.com>
Subject OCM QueryManager - Results objects
Date Mon, 22 Dec 2008 10:48:33 GMT


I'm using OCM QueryManager in a node structure like this :

* Parent1
   - Property1
   - Property2
   * Property3 (it's a @Bean field)
      - Property11
      - Property12

I wonder if there's a way to retrieve "Parent1" object while filtering on
Property11 of the Bean Property3 ?

What I do is :

        org.apache.jackrabbit.ocm.query.QueryManager mgr =
    	Filter filter = mgr.createFilter(Property3.class); 
    	filter.addLike("Property11", "...");
    	org.apache.jackrabbit.ocm.query.Query query = mgr.createQuery(filter);
    	Collection results = ocm.getObjects(query);

Inevitably, the results are of type "Property3".

Do you know if there is a way that ocm.getObjects returns parent objects ?

Thanks very much,


Antoine Larcher 
View this message in context: http://www.nabble.com/OCM-QueryManager---Results-objects-tp21125828p21125828.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.

View raw message