Package com.atlassian.bamboo.commit
Class CommitHibernateDao
- java.lang.Object
-
- org.springframework.dao.support.DaoSupport
-
- org.springframework.orm.hibernate5.support.HibernateDaoSupport
-
- com.atlassian.bamboo.persistence3.StatelessSessionHibernateDaoSupport
-
- com.atlassian.bamboo.persistence3.BambooHibernateObjectDao<Commit>
-
- com.atlassian.bamboo.commit.CommitHibernateDao
-
- All Implemented Interfaces:
CommitDao,BambooObjectDao<Commit>,org.springframework.beans.factory.InitializingBean
public class CommitHibernateDao extends BambooHibernateObjectDao<Commit> implements CommitDao
-
-
Constructor Summary
Constructors Constructor Description CommitHibernateDao()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull List<Commit>getCommitsForResult(@NotNull ResultsSummary resultsSummary)@NotNull List<UnassociatedCommit>getCommitsForUser(@NotNull String username, int max)Find recent commits for a given user.longscrollCommitsForExport(@NotNull Consumer<Commit> consumer)Scroll through and execute function for each of Commit Objects passed to function are not fully initialized.-
Methods inherited from class com.atlassian.bamboo.persistence3.BambooHibernateObjectDao
convertSearchTermToLikeExpression, countAll, countWithRestriction, delete, deleteAll, executeCountQuery, findAll, findById, merge, save, saveAll
-
Methods inherited from class com.atlassian.bamboo.persistence3.StatelessSessionHibernateDaoSupport
getCacheAwareHibernateTemplate
-
Methods inherited from class org.springframework.orm.hibernate5.support.HibernateDaoSupport
checkDaoConfig, createHibernateTemplate, currentSession, getHibernateTemplate, getSessionFactory, setHibernateTemplate, setSessionFactory
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.atlassian.bamboo.persistence3.BambooObjectDao
countAll, countWithRestriction, delete, deleteAll, findAll, findById, merge, save, saveAll
-
-
-
-
Method Detail
-
scrollCommitsForExport
public long scrollCommitsForExport(@NotNull @NotNull Consumer<Commit> consumer)Description copied from interface:CommitDaoScroll through and execute function for each of Commit Objects passed to function are not fully initialized. Collections are empty and related objects have only id set.- Specified by:
scrollCommitsForExportin interfaceCommitDao- Parameters:
consumer- consumer to accept on each of the Commit- Returns:
- number of traversed rows
-
getCommitsForResult
@NotNull public @NotNull List<Commit> getCommitsForResult(@NotNull @NotNull ResultsSummary resultsSummary)
- Specified by:
getCommitsForResultin interfaceCommitDao- Parameters:
resultsSummary-ResultsSummarywhich associated commits have to be returned- Returns:
- commits for the given
ResultsSummary
-
getCommitsForUser
@NotNull public @NotNull List<UnassociatedCommit> getCommitsForUser(@NotNull @NotNull String username, int max)
Description copied from interface:CommitDaoFind recent commits for a given user.- Specified by:
getCommitsForUserin interfaceCommitDao- Parameters:
username- to find commits for (based on author -> username association)max- maximum number of entries to retrieve- Returns:
- Representation of the commit.
-
-