|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.stratelia.webactiv.persistence.SilverpeasBeanDAOImpl<T>
public class SilverpeasBeanDAOImpl<T extends SilverpeasBeanIntf>
Field Summary |
---|
Fields inherited from interface com.stratelia.webactiv.persistence.SilverpeasBeanDAO |
---|
CONNECTION_TYPE_DATASOURCE, CONNECTION_TYPE_DATASOURCE_SILVERPEAS, CONNECTION_TYPE_EJBDATASOURCE_SILVERPEAS, CONNECTION_TYPE_JDBC_CLASSIC |
Constructor Summary | |
---|---|
SilverpeasBeanDAOImpl(String beanClassName)
|
Method Summary | |
---|---|
WAPrimaryKey |
add(Connection connection,
T bean)
|
WAPrimaryKey |
add(T bean)
create the bean and a row in DB. |
T |
findByPrimaryKey(Connection connection,
WAPrimaryKey pk)
|
T |
findByPrimaryKey(WAPrimaryKey pk)
get a bean representing a row in db from its pk |
Collection<T> |
findByWhereClause(Connection connection,
WAPrimaryKey pk,
String whereClause)
|
Collection<T> |
findByWhereClause(WAPrimaryKey pk,
String whereClause)
get a bean list, representing a specific row selection. |
void |
remove(Connection connection,
WAPrimaryKey pk)
|
void |
remove(WAPrimaryKey pk)
remove the row in db represented by the primary key. |
void |
removeWhere(Connection connection,
WAPrimaryKey pk,
String whereClause)
|
void |
removeWhere(WAPrimaryKey pk,
String whereClause)
remove all row in db represented by the where clause. |
void |
update(Connection connection,
T bean)
|
void |
update(T bean)
update the row in db with the new bean properties. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SilverpeasBeanDAOImpl(String beanClassName) throws PersistenceException
PersistenceException
Method Detail |
---|
public void remove(WAPrimaryKey pk) throws PersistenceException
SilverpeasBeanDAO
remove
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
PersistenceException
public void remove(Connection connection, WAPrimaryKey pk) throws PersistenceException
remove
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
PersistenceException
public void removeWhere(WAPrimaryKey pk, String whereClause) throws PersistenceException
SilverpeasBeanDAO
removeWhere
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
PersistenceException
public void removeWhere(Connection connection, WAPrimaryKey pk, String whereClause) throws PersistenceException
removeWhere
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
PersistenceException
public void update(T bean) throws PersistenceException
SilverpeasBeanDAO
update
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
bean
- the SilverpeasBean to update, with its complete primaryKey.
PersistenceException
public void update(Connection connection, T bean) throws PersistenceException
update
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
PersistenceException
public WAPrimaryKey add(T bean) throws PersistenceException
SilverpeasBeanDAO
add
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
bean
- the SilverpeasBeanIntf to update, with a primaryKey initialized with only spaceId
and componentId.
PersistenceException
public WAPrimaryKey add(Connection connection, T bean) throws PersistenceException
add
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
PersistenceException
public T findByPrimaryKey(WAPrimaryKey pk) throws PersistenceException
SilverpeasBeanDAO
findByPrimaryKey
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
pk
- the complete beans primary key
PersistenceException
public T findByPrimaryKey(Connection connection, WAPrimaryKey pk) throws PersistenceException
findByPrimaryKey
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
PersistenceException
public Collection<T> findByWhereClause(WAPrimaryKey pk, String whereClause) throws PersistenceException
SilverpeasBeanDAO
findByWhereClause
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
pk
- the beans primary key initialized with at least spaceId and componentId.whereClause
- The where clause to put in select request. If null, all SilverpeasBeanIntfs
will be selected (all rows in the table).
PersistenceException
public Collection<T> findByWhereClause(Connection connection, WAPrimaryKey pk, String whereClause) throws PersistenceException
findByWhereClause
in interface SilverpeasBeanDAO<T extends SilverpeasBeanIntf>
PersistenceException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |