public final class DefaultPersister extends Object implements Persister
This object uses DmlPersistExecute to perform the actual persist execution.
This object:
DefaultPersistExecute| Constructor and Description |
|---|
DefaultPersister(SpiEbeanServer server,
Binder binder,
BeanDescriptorManager descMgr,
PstmtBatch pstmtBatch) |
| Modifier and Type | Method and Description |
|---|---|
int |
delete(Class<?> beanType,
Object id,
Transaction transaction)
Delete by Id.
|
void |
delete(Object bean,
Transaction t)
Delete the bean with the explicit transaction.
|
void |
deleteMany(Class<?> beanType,
Collection<?> ids,
Transaction transaction)
Delete by a List of Id's.
|
int |
deleteManyToManyAssociations(Object ownerBean,
String propertyName,
Transaction t)
Delete the associations of a ManyToMany given the owner bean and the property name of the ManyToMany.
|
int |
executeCallable(CallableSql callSql,
Transaction t)
Execute the CallableSql.
|
int |
executeOrmUpdate(Update<?> update,
Transaction t)
Execute the orm update.
|
int |
executeSqlUpdate(SqlUpdate updSql,
Transaction t)
Execute the updateSql.
|
void |
forceInsert(Object bean,
Transaction t)
Explicitly specify to insert this bean.
|
void |
forceUpdate(Object bean,
Set<String> updateProps,
Transaction t,
boolean deleteMissingChildren,
boolean updateNullProperties)
Force an Update using the given bean.
|
void |
save(Object bean,
Transaction t)
Insert or update the bean depending on its state.
|
void |
saveAssociation(Object parentBean,
String propertyName,
Transaction t)
Save an association (OneToMany, ManyToOne, OneToOne or ManyToMany).
|
void |
saveManyToManyAssociations(Object ownerBean,
String propertyName,
Transaction t)
Save the associations of a ManyToMany given the owner bean and the
propertyName of the ManyToMany collection.
|
public DefaultPersister(SpiEbeanServer server, Binder binder, BeanDescriptorManager descMgr, PstmtBatch pstmtBatch)
public int executeCallable(CallableSql callSql, Transaction t)
executeCallable in interface Persisterpublic int executeOrmUpdate(Update<?> update, Transaction t)
executeOrmUpdate in interface Persisterpublic int executeSqlUpdate(SqlUpdate updSql, Transaction t)
executeSqlUpdate in interface Persisterpublic void forceUpdate(Object bean, Set<String> updateProps, Transaction t, boolean deleteMissingChildren, boolean updateNullProperties)
forceUpdate in interface Persisterpublic void save(Object bean, Transaction t)
Persisterpublic void forceInsert(Object bean, Transaction t)
forceInsert in interface Persisterpublic void delete(Object bean, Transaction t)
public void deleteMany(Class<?> beanType, Collection<?> ids, Transaction transaction)
deleteMany in interface Persisterpublic int delete(Class<?> beanType, Object id, Transaction transaction)
public int deleteManyToManyAssociations(Object ownerBean, String propertyName, Transaction t)
PersisterdeleteManyToManyAssociations in interface Persisterpublic void saveManyToManyAssociations(Object ownerBean, String propertyName, Transaction t)
PersistersaveManyToManyAssociations in interface Persisterpublic void saveAssociation(Object parentBean, String propertyName, Transaction t)
PersistersaveAssociation in interface PersisterparentBean - the bean that owns the association.propertyName - the name of the property to save.t - the transaction to use.Copyright © 2014. All Rights Reserved.