|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.atlassian.bamboo.variable.CustomVariableContextImpl
public class CustomVariableContextImpl
Constructor Summary | |
---|---|
CustomVariableContextImpl()
|
Method Summary | |
---|---|
void |
addCustomData(java.lang.String key,
java.lang.String value)
Adds a VariableType.MANUAL variable to ThreadLocal state. |
void |
clearContext()
Clear ThreadLocal state. |
java.util.Map<java.lang.String,VariableSubstitutionContext> |
getSubstitutedVariables()
Get all the variables that have previously been substituted in this thread. |
java.util.Map<java.lang.String,java.lang.String> |
getVariables(BuildContext buildContext)
Get all variables from buildContext. |
java.lang.String |
removeAllVariables(java.lang.String value)
Given a string array, remove all variable patterns. |
void |
setAdministrationConfigurationManager(AdministrationConfigurationManager administrationConfigurationManager)
|
void |
setAgentContext(AgentContext agentContext)
|
void |
setBuildContext(BuildContext buildContext)
Set buildContext reference in ThreadLocal state. |
void |
setBuildDirectoryManager(BuildDirectoryManager buildDirectoryManager)
|
void |
setBuildLoggerManager(BuildLoggerManager buildLoggerManager)
|
void |
setCapabilityContext(CapabilityContext capabilityContext)
|
void |
setPlan(PlanIdentifier planIdentifier,
java.util.Map<java.lang.String,VariableDefinitionContext> variablesContextMap)
Sets Plan reference and variable definitions in ThreadLocal state. |
void |
setVariables(java.util.Map<java.lang.String,VariableDefinitionContext> variablesContextMap)
Set variable definitions in ThreadLocal state. |
java.lang.String |
substituteString(java.lang.String value)
Substitutes variables in the input string with their values using data from existing ThreadLocal state. |
java.lang.String |
substituteString(java.lang.String value,
BuildContext buildContext,
BuildLogger buildLogger)
Substitutes variables in the input string with their values using provided data, i.e. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CustomVariableContextImpl()
Method Detail |
---|
public void setPlan(@NotNull PlanIdentifier planIdentifier, @Nullable java.util.Map<java.lang.String,VariableDefinitionContext> variablesContextMap)
CustomVariableContext
ThreadLocal
state.
Clears history of substituted variables (CustomVariableContext.getSubstitutedVariables()
setPlan
in interface CustomVariableContext
planIdentifier
- plan identifiervariablesContextMap
- variable definitions (including plan variables)public void setVariables(java.util.Map<java.lang.String,VariableDefinitionContext> variablesContextMap)
CustomVariableContext
ThreadLocal
state.
Clears history of substituted variables (CustomVariableContext.getSubstitutedVariables()
setVariables
in interface CustomVariableContext
variablesContextMap
- variable definitionspublic void setBuildContext(BuildContext buildContext)
CustomVariableContext
ThreadLocal
state.
Sets the variable definitions to those contained in the context.
BuildContext has priority over Plan when resolving the variables.
setBuildContext
in interface CustomVariableContext
public void clearContext()
CustomVariableContext
ThreadLocal
state.
clearContext
in interface CustomVariableContext
@NotNull public java.util.Map<java.lang.String,VariableSubstitutionContext> getSubstitutedVariables()
CustomVariableContext
getSubstitutedVariables
in interface CustomVariableContext
public void addCustomData(java.lang.String key, java.lang.String value)
CustomVariableContext
VariableType.MANUAL
variable to ThreadLocal
state.
addCustomData
in interface CustomVariableContext
key
- name of the variablevalue
- value of the variablepublic java.lang.String substituteString(java.lang.String value)
CustomVariableContext
ThreadLocal
state.
substituteString
in interface CustomVariableContext
value
- input string
public java.lang.String substituteString(java.lang.String value, @Nullable BuildContext buildContext, BuildLogger buildLogger)
CustomVariableContext
ThreadLocal
state.
substituteString
in interface CustomVariableContext
value
- input stringbuildContext
- build contextbuildLogger
- build logger
@NotNull public java.lang.String removeAllVariables(@NotNull java.lang.String value)
removeAllVariables
in interface CustomVariableContext
value
- string values to be analyzed
@NotNull public java.util.Map<java.lang.String,java.lang.String> getVariables(BuildContext buildContext)
CustomVariableContext
getVariables
in interface CustomVariableContext
public void setBuildLoggerManager(BuildLoggerManager buildLoggerManager)
public void setCapabilityContext(CapabilityContext capabilityContext)
public void setAdministrationConfigurationManager(AdministrationConfigurationManager administrationConfigurationManager)
public void setAgentContext(AgentContext agentContext)
public void setBuildDirectoryManager(BuildDirectoryManager buildDirectoryManager)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |