public class ByObjectStatic extends Object
Modifier and Type | Method and Description |
---|---|
protected void |
copyFieldsTo(edu.internet2.middleware.grouper.hibernate.ByQueryBase byQueryBase)
copy field to, better by a ByObject...
|
void |
delete(Collection<?> collection)
call hibernate method "delete" on a list of objects
HibernateSession.byObjectStatic().delete(collection);
|
void |
delete(Object object)
call hibernate method "delete" on a list of objects
HibernateSession.byObjectStatic().delete(Rosetta.getDAO(_f));
|
void |
deleteBatch(Collection<?> collection)
call hibernate method "delete" on a list of objects
HibernateSession.byObjectStatic().deleteBatch(Rosetta.getDAO(_f));
|
protected HibernateSession |
getHibernateSession() |
boolean |
isIgnoreHooks()
if we should ignore hooks
|
<T> T |
load(Class<T> theClass,
Serializable id)
call hibernate "load" method on an object
|
static void |
main(String[] args) |
void |
save(Collection<?> collection)
call hibernate method "save" on a list of objects
HibernateSession.byObjectStatic().save(collection);
|
Serializable |
save(Object object)
call hibernate method "save" on an object
HibernateSession.byObjectStatic().save(dao);
|
void |
saveBatch(Collection<?> collection)
call hibernate method "save" on a collection of objects in batch
|
void |
saveOrUpdate(Collection<?> collection)
call hibernate method "saveOrUpdate" on a list of objects
HibernateSession.byObjectStatic().saveOrUpdate(collection);
|
void |
saveOrUpdate(Object object)
call hibernate "saveOrUpdate" method on an object
|
protected edu.internet2.middleware.grouper.hibernate.ByQueryBase |
set(HibernateSession theHibernateSession2)
set the hibernate session to re-use, or null for a new one
byCriteriaStatic().set(hibernateSession2).select(...)
|
ByObjectStatic |
setCacheable(Boolean cacheable)
assign if this query is cacheable or not.
|
ByObjectStatic |
setCacheRegion(String cacheRegion)
cache region for cache
|
ByObjectStatic |
setEntityName(String theEntityName)
entity name if the object is mapped to more than one table
|
ByObjectStatic |
setGrouperTransactionType(GrouperTransactionType theGrouperTransactionType)
assign a different grouperTransactionType (e.g.
|
ByObjectStatic |
setIgnoreHooks(boolean theIgnoreHooks)
if we should ignore hooks
|
String |
toString()
string value for error handling
|
void |
update(Collection<?> collection)
call hibernate method "update" on a list of objects
HibernateSession.byObjectStatic().update(collection);
|
void |
update(Object object)
call hibernate "update" method on an object
|
void |
updateBatch(Collection<?> collection)
call hibernate method "updateBatch" on a list of objects
HibernateSession.byObjectStatic().updateBatch(collection);
|
public ByObjectStatic setGrouperTransactionType(GrouperTransactionType theGrouperTransactionType)
theGrouperTransactionType
- public ByObjectStatic setCacheable(Boolean cacheable)
cacheable
- the cacheable to setpublic String toString()
public ByObjectStatic setCacheRegion(String cacheRegion)
cacheRegion
- the cacheRegion to setpublic ByObjectStatic setEntityName(String theEntityName)
theEntityName
- the entity name of the objectpublic void update(Collection<?> collection) throws GrouperDAOException
call hibernate method "update" on a list of objects HibernateSession.byObjectStatic().update(collection);
collection
- is collection of objects to update in one transaction. If null or empty just ignoreGrouperDAOException
public void update(Object object) throws GrouperDAOException
object
- to updateGrouperDAOException
public <T> T load(Class<T> theClass, Serializable id) throws GrouperDAOException
T
- theClass
- to loadid
- GrouperDAOException
public void saveOrUpdate(Collection<?> collection) throws GrouperDAOException
call hibernate method "saveOrUpdate" on a list of objects HibernateSession.byObjectStatic().saveOrUpdate(collection);
collection
- is collection of objects to saveOrUpdate in one transaction. If null or empty just ignoreGrouperDAOException
public void saveOrUpdate(Object object) throws GrouperDAOException
object
- to updateGrouperDAOException
public void save(Collection<?> collection) throws GrouperDAOException
call hibernate method "save" on a list of objects HibernateSession.byObjectStatic().save(collection);
collection
- is collection of objects to save in one transaction. If null or empty just ignoreGrouperDAOException
public Serializable save(Object object) throws GrouperDAOException
call hibernate method "save" on an object HibernateSession.byObjectStatic().save(dao);
object
- to saveGrouperDAOException
public void saveBatch(Collection<?> collection) throws GrouperDAOException
call hibernate method "save" on a collection of objects in batch
collection
- of objectsGrouperDAOException
public void delete(Collection<?> collection) throws GrouperDAOException
call hibernate method "delete" on a list of objects HibernateSession.byObjectStatic().delete(collection);
collection
- is collection of objects to delete in one transaction. If null or empty just ignoreGrouperDAOException
protected void copyFieldsTo(edu.internet2.middleware.grouper.hibernate.ByQueryBase byQueryBase)
public void delete(Object object) throws GrouperDAOException
call hibernate method "delete" on a list of objects HibernateSession.byObjectStatic().delete(Rosetta.getDAO(_f));
object
- is an object (if collection will still work), if null, will probably throw exceptionGrouperDAOException
public void deleteBatch(Collection<?> collection) throws GrouperDAOException
call hibernate method "delete" on a list of objects HibernateSession.byObjectStatic().deleteBatch(Rosetta.getDAO(_f));
collection
- is an object (if collection will still work), if null, will probably throw exceptionGrouperDAOException
public ByObjectStatic setIgnoreHooks(boolean theIgnoreHooks)
ByQueryBase.setIgnoreHooks(boolean)
public void updateBatch(Collection<?> collection) throws GrouperDAOException
call hibernate method "updateBatch" on a list of objects HibernateSession.byObjectStatic().updateBatch(collection);
collection
- is collection of objects to update in one transaction. If null or empty just ignoreGrouperDAOException
public boolean isIgnoreHooks()
protected HibernateSession getHibernateSession()
protected edu.internet2.middleware.grouper.hibernate.ByQueryBase set(HibernateSession theHibernateSession2)
theHibernateSession2
- is the session to reusepublic static void main(String[] args)
args
- Copyright © 2016 Internet2. All rights reserved.