Class InputParserImpl
- java.lang.Object
-
- com.atlassian.bamboo.plugins.rest.common.InputParserImpl
-
- All Implemented Interfaces:
InputParser
@Component public class InputParserImpl extends Object implements InputParser
Utility service for parsing PlanKeys
-
-
Constructor Summary
Constructors Constructor Description InputParserImpl(com.atlassian.sal.api.message.I18nResolver i18nResolver)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull PlanKey
parseChainKey(@Nullable String chainKeyString)
Parse a chain key from the input string.@NotNull PlanKey
parseJobKey(@NotNull PlanKey chainKey, @Nullable String jobKeyString)
Parse a job key from the input string.@NotNull PlanKey
parseJobKey(@Nullable String jobKeyString)
Parse a job key from the input string.
-
-
-
Method Detail
-
parseChainKey
@NotNull public @NotNull PlanKey parseChainKey(@Nullable @Nullable String chainKeyString)
Parse a chain key from the input string.- Specified by:
parseChainKey
in interfaceInputParser
- Parameters:
chainKeyString
- to parse.- Returns:
- parsed key.
- Throws:
NotFoundException
- if the key is invalid.
-
parseJobKey
@NotNull public @NotNull PlanKey parseJobKey(@Nullable @Nullable String jobKeyString)
Parse a job key from the input string.- Specified by:
parseJobKey
in interfaceInputParser
- Parameters:
jobKeyString
- to parse.- Returns:
- parsed key.
- Throws:
NotFoundException
- if the key is invalid.
-
parseJobKey
@NotNull public @NotNull PlanKey parseJobKey(@NotNull @NotNull PlanKey chainKey, @Nullable @Nullable String jobKeyString)
Parse a job key from the input string. Will work if the jobKeyString is in short form or long form.- Specified by:
parseJobKey
in interfaceInputParser
- Parameters:
chainKey
- of plan job key is for.jobKeyString
- to parse.- Returns:
- parsed key.
- Throws:
NotFoundException
- if the key is invalid.
-
-