com.atlassian.bamboo.plan.artifact
Class ArtifactDefinitionHibernateDao
java.lang.Object
org.springframework.dao.support.DaoSupport
org.springframework.orm.hibernate3.support.HibernateDaoSupport
com.atlassian.bamboo.persistence3.StatelessSessionHibernateDaoSupport
com.atlassian.bamboo.persistence3.BambooHibernateObjectDao<ArtifactDefinition>
com.atlassian.bamboo.plan.artifact.ArtifactDefinitionHibernateDao
- All Implemented Interfaces:
- BambooObjectDao<ArtifactDefinition>, ArtifactDefinitionDao, org.springframework.beans.factory.InitializingBean
public class ArtifactDefinitionHibernateDao
- extends BambooHibernateObjectDao<ArtifactDefinition>
- implements ArtifactDefinitionDao
Fields inherited from class org.springframework.dao.support.DaoSupport |
logger |
Methods inherited from class com.atlassian.bamboo.persistence3.BambooHibernateObjectDao |
countAll, countWithRestriction, delete, deleteAll, execute, executeCountQuery, executeReturnInt, executeReturnLong, findAll, findById, save, saveAll |
Methods inherited from class org.springframework.orm.hibernate3.support.HibernateDaoSupport |
checkDaoConfig, convertHibernateAccessException, createHibernateTemplate, getHibernateTemplate, getSession, getSession, getSessionFactory, releaseSession, setHibernateTemplate, setSessionFactory |
Methods inherited from class org.springframework.dao.support.DaoSupport |
afterPropertiesSet, initDao |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ArtifactDefinitionHibernateDao
public ArtifactDefinitionHibernateDao()
findById
@Nullable
public ArtifactDefinition findById(long id)
- Description copied from interface:
ArtifactDefinitionDao
- Get artifact definition of specified id
- Specified by:
findById
in interface ArtifactDefinitionDao
- Parameters:
id
- id of artifact definition
- Returns:
- artifact definition of specified id or null if not found
findByName
@Nullable
public ArtifactDefinition findByName(@NotNull
ImmutablePlan plan,
@NotNull
String name)
- Description copied from interface:
ArtifactDefinitionDao
- Find artifact definition of a given name associated with a producer job.
- Specified by:
findByName
in interface ArtifactDefinitionDao
- Parameters:
plan
- plan which associated artifact definition should be retrievedname
- name to search among plan's artifact definitions
- Returns:
- artifact definition matching plan and label or null if not found
findByNameInChain
@Nullable
public ArtifactDefinition findByNameInChain(@NotNull
ImmutableChain chain,
@NotNull
String name)
- Description copied from interface:
ArtifactDefinitionDao
- Find artifact definition of a given name which has sharedArtifact property set to true,
associated with a producer job that belongs to the chain.
- Specified by:
findByNameInChain
in interface ArtifactDefinitionDao
- Parameters:
chain
- chain which associated artifact definition should be retrievedname
- name to search among plan's artifact definitions
- Returns:
- artifact definition matching plan and label or null if not found
findSharedArtifactsByChain
@NotNull
public List<ArtifactDefinition> findSharedArtifactsByChain(@NotNull
ImmutableChain chain)
- Description copied from interface:
ArtifactDefinitionDao
- Find all shared artifacts that exist for a particular chain.
- Specified by:
findSharedArtifactsByChain
in interface ArtifactDefinitionDao
- Parameters:
chain
- chain which associated artifact definitions should be retrieved
- Returns:
- shared artifacts that exist for the specified particular chain
findAll
@NotNull
public Collection<? extends ArtifactDefinition> findAll()
- Description copied from interface:
ArtifactDefinitionDao
- Find all artifact definitions
- Specified by:
findAll
in interface ArtifactDefinitionDao
- Returns:
- Collection of all artifact definitions
findByProducer
@NotNull
public List<ArtifactDefinition> findByProducer(@NotNull
ImmutablePlan plan)
- Description copied from interface:
ArtifactDefinitionDao
- Get list of artifact definitions associated with a plan
- Specified by:
findByProducer
in interface ArtifactDefinitionDao
- Parameters:
plan
- plan which associated artifact definitions should be retrieved
- Returns:
- list of artifact definitions
removeByProducer
public void removeByProducer(@NotNull
Plan plan)
- Description copied from interface:
ArtifactDefinitionDao
- Remove all artifact definitions associated with a plan.
- Specified by:
removeByProducer
in interface ArtifactDefinitionDao
- Parameters:
plan
- plan which associated artifact definitions should be removed
Copyright © 2015 Atlassian Software Systems Pty Ltd. All rights reserved.