1 19 20 package org.apache.cayenne.dba.frontbase; 21 22 import java.sql.Connection ; 23 24 import org.apache.cayenne.access.jdbc.SelectAction; 25 import org.apache.cayenne.access.trans.SelectTranslator; 26 import org.apache.cayenne.dba.DbAdapter; 27 import org.apache.cayenne.dba.JdbcActionBuilder; 28 import org.apache.cayenne.map.EntityResolver; 29 import org.apache.cayenne.query.SQLAction; 30 import org.apache.cayenne.query.SelectQuery; 31 32 class FrontBaseActionBuilder extends JdbcActionBuilder { 33 34 FrontBaseActionBuilder(DbAdapter adapter, EntityResolver resolver) { 35 super(adapter, resolver); 36 } 37 38 public SQLAction objectSelectAction(SelectQuery query) { 39 return new SelectAction(query, adapter, entityResolver) { 40 41 protected SelectTranslator createTranslator(Connection connection) { 42 SelectTranslator translator = new FrontBaseSelectTranslator(); 43 translator.setQuery(query); 44 translator.setAdapter(adapter); 45 translator.setEntityResolver(getEntityResolver()); 46 translator.setConnection(connection); 47 return translator; 48 } 49 }; 50 } 51 } 52 | Popular Tags |