Package net.hasor.db.transaction.interceptor.simple

Examples of net.hasor.db.transaction.interceptor.simple.SimpleTranInterceptorModule


        apiBinder.bindType(DataSource.class).nameWith(dsName).toInstance(dataSource);
        //2.绑定JdbcTemplate接口实现
        apiBinder.bindType(JdbcTemplate.class).nameWith(dsName).toProvider(new JdbcTemplateProvider(dataSource));
        apiBinder.bindType(JdbcTemplate.class).idWith(dsName).toProvider(new JdbcTemplateProvider(dataSource));
        //3.启用默认事务拦截器
        apiBinder.installModule(new SimpleTranInterceptorModule(dataSource));
    }
View Full Code Here


        //3.绑定DataSource接口实现
        apiBinder.bindType(DataSource.class).toInstance(dataSource);
        //4.绑定JdbcTemplate接口实现
        apiBinder.bindType(JdbcTemplate.class).toProvider(new JdbcTemplateProvider(dataSource));
        //5.启用默认事务拦截器
        apiBinder.installModule(new SimpleTranInterceptorModule(dataSource));
    }
View Full Code Here

        //1.绑定DataSource接口实现
        apiBinder.bindType(DataSource.class).idWith(this.dataSourceID).toInstance(this.dataSource);
        //2.绑定JdbcTemplate接口实现
        apiBinder.bindType(JdbcTemplate.class).toProvider(new JdbcTemplateProvider(this.dataSource));
        //3.启用默认事务拦截器
        apiBinder.installModule(new SimpleTranInterceptorModule(this.dataSource));
    }
View Full Code Here

TOP

Related Classes of net.hasor.db.transaction.interceptor.simple.SimpleTranInterceptorModule

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.