@SuppressWarnings("unchecked")
private GenericDaoJpa loadCachingDao() {
if (preloadConfiguration == null) {
throw new RuntimeException( "The Caching Configuration property must be set to use a caching dao." );
}
PreloadableCacheableGenericDaoJpa dao = new PreloadableCacheableGenericDaoJpa( bo );
dao.setPreloadConfiguration( preloadConfiguration );
dao.setEntityManagerFactory( entityManagerFactory );
dao.setNewSelectStatement(newSelect);
dao.setQueryHints(queryHints);
dao.preload();
this.addAdvisor( new CachingAdvisor() );
return dao;
}