1 19 package org.apache.cayenne.query; 20 21 import org.apache.cayenne.ejbql.EJBQLCompiledExpression; 22 import org.apache.cayenne.map.EntityResolver; 23 import org.apache.cayenne.map.ObjEntity; 24 25 31 class EJBQLQueryMetadata extends BaseQueryMetadata { 32 33 private SQLResultSetMapping resultSetMapping; 34 35 void setResultSetMapping(SQLResultSetMapping resultSetMapping) { 36 this.resultSetMapping = resultSetMapping; 37 } 38 39 public SQLResultSetMapping getResultSetMapping() { 40 return resultSetMapping; 41 } 42 43 boolean resolve(EntityResolver resolver, EJBQLQuery query) { 44 EJBQLCompiledExpression expression = query.getExpression(resolver); 45 setResultSetMapping(expression.getResultSetMapping()); 46 47 ObjEntity root = expression.getRootDescriptor().getEntity(); 48 49 return super.resolve(root, resolver, null); 51 } 52 } 53 | Popular Tags |