Class DelegatingParametersProvider
- java.lang.Object
-
- jetbrains.buildServer.parameters.impl.DelegatingParametersProvider
-
- All Implemented Interfaces:
ContainsAwareParametersProvider,ParametersProvider
public class DelegatingParametersProvider extends Object implements ContainsAwareParametersProvider
Parameters Provider implementation that delegates to a given map. This is recommended to ensure map is not changed outside.- Since:
- 7.0
- Author:
- Eugene Petrenko (eugene.petrenko@gmail.com) Date: 14.09.11 14:01
-
-
Constructor Summary
Constructors Constructor Description DelegatingParametersProvider(Map<String,String> map)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancontains(String key)Returns true if this parameters provider contains specified keyStringget(String key)Map<String,String>getAll()Allows to get map of the provided parameters.intsize()Returns the number of parameters in this parameters provider.StringtoString()
-
-
-
Method Detail
-
get
public String get(@NotNull String key)
- Specified by:
getin interfaceParametersProvider- Parameters:
key- the name of the parameter- Returns:
- the value associated with a key, or null if the parameter with the key cannot be found.
-
size
public int size()
Description copied from interface:ParametersProviderReturns the number of parameters in this parameters provider. This is the size of the map returned by getAll method.- Specified by:
sizein interfaceParametersProvider
-
getAll
public Map<String,String> getAll()
Description copied from interface:ParametersProviderAllows to get map of the provided parameters. Note that get method can provide more parameters then are returned by this method. However, all the parameters returned by this method should also be available via get method.- Specified by:
getAllin interfaceParametersProvider- Returns:
- copy of the backed data
-
contains
public boolean contains(@NotNull String key)Description copied from interface:ContainsAwareParametersProviderReturns true if this parameters provider contains specified key- Specified by:
containsin interfaceContainsAwareParametersProvider- Parameters:
key- key of interest- Returns:
- see above
-
-