|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.dao.support.DaoSupport
public abstract class DaoSupport
Generic base class for DAOs, defining template methods for DAO initialization.
Extended by Spring's specific DAO support classes, such as: JdbcDaoSupport, JdoDaoSupport, etc.
JdbcDaoSupport
,
JdoDaoSupport
Field Summary | |
---|---|
protected Log |
logger
Logger available to subclasses |
Constructor Summary | |
---|---|
DaoSupport()
|
Method Summary | |
---|---|
void |
afterPropertiesSet()
Invoked by a BeanFactory after it has set all bean properties supplied (and satisfied BeanFactoryAware and ApplicationContextAware). |
protected abstract void |
checkDaoConfig()
Abstract subclasses must override this to check their configuration. |
protected void |
initDao()
Concrete subclasses can override this for custom initialization behavior. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final Log logger
Constructor Detail |
---|
public DaoSupport()
Method Detail |
---|
public final void afterPropertiesSet() throws IllegalArgumentException, BeanInitializationException
InitializingBean
This method allows the bean instance to perform initialization only possible when all bean properties have been set and to throw an exception in the event of misconfiguration.
afterPropertiesSet
in interface InitializingBean
IllegalArgumentException
BeanInitializationException
protected abstract void checkDaoConfig() throws IllegalArgumentException
Implementors should be marked as final
IllegalArgumentException
- in case of illegal configurationprotected void initDao() throws Exception
Exception
- if DAO initialization fails
(will be rethrown as a BeanInitializationException)BeanInitializationException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |