public class VariableDefinitionHibernateDao extends BambooHibernateObjectDao<VariableDefinition> implements VariableDefinitionDao
| Constructor and Description |
|---|
VariableDefinitionHibernateDao(TransactionAndHibernateTemplate transactionTemplate) |
| Modifier and Type | Method and Description |
|---|---|
long |
countAll() |
int |
countVariablesByEnvironmentId(long environmentId)
Count variables associated with deployment environment
|
int |
deleteByDeploymentVersion(DeletionSQLAdapter deletionAdapter)
Delete VariableDefinitions related to DeploymentVersions.
|
int |
deleteByEnvironment(DeletionSQLAdapter deletionAdapter)
Delete VariableDefinitions related to Environments.
|
int |
deleteByPlan(long planId)
Delete VariableDefinitions related to a plan.
|
Collection<? extends VariableDefinition> |
findAll()
Find all variable definitions
|
VariableDefinition |
findById(long id)
Find variable definition of specified id
|
VariableDefinition |
findGlobalVariableByKey(String key)
Find global variable by its key
|
List<VariableDefinition> |
findGlobalVariables()
Find global variable definitions.
|
VariableDefinition |
findPlanVariableByKey(PlanIdentifier plan,
String key)
Find plan variable by its key
|
Iterable<VariableDefinition> |
findVariablesByEnvironmentId(long environmentId)
Find variables associated with deployment environment
|
List<VariableDefinition> |
findVariablesByPlan(PlanIdentifier plan)
Find plan variable definitions for a given plan
|
Iterable<VariableDefinition> |
findVariablesByVersionId(long deploymentVersionId)
Find variables associated with deployment version
|
void |
save(VariableDefinition variableDefinition)
Saves the given entity.
|
countAll, countWithRestriction, delete, deleteAll, executeCountQuery, findAll, findById, merge, saveAllgetCacheAwareHibernateTemplatecheckDaoConfig, createHibernateTemplate, currentSession, getHibernateTemplate, getSessionFactory, setHibernateTemplate, setSessionFactoryclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcountAll, countWithRestriction, delete, deleteAll, findAll, findById, merge, saveAllpublic VariableDefinitionHibernateDao(TransactionAndHibernateTemplate transactionTemplate)
public VariableDefinition findById(long id)
VariableDefinitionDaofindById in interface VariableDefinitionDaoid - id of variable definition@NotNull public List<VariableDefinition> findGlobalVariables()
VariableDefinitionDaofindGlobalVariables in interface VariableDefinitionDaopublic void save(@NotNull
VariableDefinition variableDefinition)
BambooObjectDaoEntityObject this method will:
- update EntityObject.getLastModificationDate()
- set EntityObject.getCreationDate() if the object has not been savedsave in interface BambooObjectDao<VariableDefinition>save in class BambooHibernateObjectDao<VariableDefinition>variableDefinition - entity to be saved@NotNull public List<VariableDefinition> findVariablesByPlan(@NotNull PlanIdentifier plan)
VariableDefinitionDaofindVariablesByPlan in interface VariableDefinitionDaoplan - plan which associated variable definition should be retrievedpublic int countVariablesByEnvironmentId(long environmentId)
VariableDefinitionDaocountVariablesByEnvironmentId in interface VariableDefinitionDaoenvironmentId - id of a deployment environment@NotNull public Iterable<VariableDefinition> findVariablesByEnvironmentId(long environmentId)
VariableDefinitionDaofindVariablesByEnvironmentId in interface VariableDefinitionDaoenvironmentId - id of a deployment environment@NotNull public Iterable<VariableDefinition> findVariablesByVersionId(long deploymentVersionId)
VariableDefinitionDaofindVariablesByVersionId in interface VariableDefinitionDaodeploymentVersionId - id of a deployment versionpublic int deleteByEnvironment(@NotNull
DeletionSQLAdapter deletionAdapter)
VariableDefinitionDaodeleteByEnvironment in interface VariableDefinitionDaodeletionAdapter - DeletionSQLAdapter.getInClause()public int deleteByDeploymentVersion(@NotNull
DeletionSQLAdapter deletionAdapter)
VariableDefinitionDaodeleteByDeploymentVersion in interface VariableDefinitionDaopublic int deleteByPlan(long planId)
VariableDefinitionDaodeleteByPlan in interface VariableDefinitionDaopublic VariableDefinition findPlanVariableByKey(@NotNull PlanIdentifier plan, @NotNull String key)
VariableDefinitionDaofindPlanVariableByKey in interface VariableDefinitionDaoplan - plan used to filter variableskey - key which identifies plan variable definitionpublic VariableDefinition findGlobalVariableByKey(@NotNull String key)
VariableDefinitionDaofindGlobalVariableByKey in interface VariableDefinitionDaokey - key which identifies global variable definition@NotNull public Collection<? extends VariableDefinition> findAll()
VariableDefinitionDaofindAll in interface VariableDefinitionDaopublic long countAll()
countAll in interface VariableDefinitionDaoCopyright © 2019 Atlassian Software Systems Pty Ltd. All rights reserved.