All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.jpattern.orm.script.SessionParserCallback Maven / Gradle / Ivy

There is a newer version: 3.5.1
Show newest version
package com.jpattern.orm.script;

import com.jpattern.logger.ILogger;
import com.jpattern.orm.logger.OrmLogger;
import com.jpattern.orm.session.SessionSqlPerformer;
import com.jpattern.orm.session.SqlPerformer;

/**
 * 
 * @author Francesco Cina
 *
 * 02/lug/2011
 */
public class SessionParserCallback implements IParserCallback {

	private final SqlPerformer sqlExec;
	private final ILogger logger;

	public SessionParserCallback(SessionSqlPerformer session) {
		logger = OrmLogger.getOrmLogger(getClass());
		sqlExec = session.sqlPerformer();
	}

	@Override
	public void parseAction(String sqlStatement) {
		logger.trace("parseAction", "Execute statement: " + sqlStatement);
		sqlExec.update(sqlStatement);
	}
	
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy