com.atlassian.bamboo.variable
Interface VariableDefinitionDao

All Superinterfaces:
BambooObjectDao<VariableDefinition>
All Known Implementing Classes:
VariableDefinitionHibernateDao

public interface VariableDefinitionDao
extends BambooObjectDao<VariableDefinition>


Method Summary
 java.util.Collection<? extends VariableDefinition> findAll()
          Find all variable definitions
 VariableDefinition findById(long id)
          Find variable definition of specified id
 VariableDefinition findGlobalVariableByKey(java.lang.String key)
          Find global variable by its key
 java.util.List<VariableDefinition> findGlobalVariables()
          Find global variable definitions.
 VariableDefinition findPlanVariableByKey(Plan plan, java.lang.String key)
          Find plan variable by its key
 java.util.List<VariableDefinition> findVariablesByPlan(Plan plan)
          Find plan variable definitions for a given plan
 
Methods inherited from interface com.atlassian.bamboo.persistence3.BambooObjectDao
delete, deleteAll, executeReturnLong, findAll, findById, save, saveAll
 

Method Detail

findById

@Nullable
VariableDefinition findById(long id)
Find variable definition of specified id

Parameters:
id - id of variable definition
Returns:
variable definition of specified id or null if not found

findGlobalVariables

@NotNull
java.util.List<VariableDefinition> findGlobalVariables()
Find global variable definitions.

Returns:
global variable definition collection

findGlobalVariableByKey

@Nullable
VariableDefinition findGlobalVariableByKey(@NotNull
                                                    java.lang.String key)
Find global variable by its key

Parameters:
key - key which identifies global variable definition
Returns:
variable definition or null if not found

findVariablesByPlan

@NotNull
java.util.List<VariableDefinition> findVariablesByPlan(Plan plan)
Find plan variable definitions for a given plan

Parameters:
plan - plan which associated variable definition should be retrieved
Returns:
variable definition matching plan or empty collection if not found

findPlanVariableByKey

@Nullable
VariableDefinition findPlanVariableByKey(@NotNull
                                                  Plan plan,
                                                  @NotNull
                                                  java.lang.String key)
Find plan variable by its key

Parameters:
plan - plan used to filter variables
key - key which identifies plan variable definition
Returns:
variable definition or null if not found

findAll

@NotNull
java.util.Collection<? extends VariableDefinition> findAll()
Find all variable definitions

Returns:
Collection of all variable definitions


Copyright © 2011 Atlassian. All Rights Reserved.