cn.sylinx.hbatis.ext.xmapper.repository.DaoSingleton Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hbatis-xmapper Show documentation
Show all versions of hbatis-xmapper Show documentation
hbatis-xmapper is a simple orm framework, extends hbatis-core
The newest version!
package cn.sylinx.hbatis.ext.xmapper.repository;
import cn.sylinx.hbatis.ext.AbstractDaoSingleton;
import cn.sylinx.hbatis.ext.xmapper.spi.XmapperServiceManager;
public class DaoSingleton extends AbstractDaoSingleton {
public static final DaoSingleton ME = new DaoSingleton();
@Override
protected String getDefaultDatasourceName() {
return XmapperServiceManager.getXmapperService().getDatasourceName();
}
@Override
protected DaoService createDaoService(String datasourceName) {
return new DaoServiceImpl(new RepositoryImpl(datasourceName));
}
}