Class AbstractMapParametersProvider

    • Constructor Detail

      • AbstractMapParametersProvider

        public AbstractMapParametersProvider​(@NotNull
                                             Map<String,​String> parameters)
        Create map provider wrapping a given map. No copy is done, all requests are redirected to the given map Given map would be used for both read and writes
        Parameters:
        parameters - map to adapt to MapParametersProvider
    • Method Detail

      • get

        public String get​(@NotNull
                          String key)
        Specified by:
        get in interface ParametersProvider
        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.
      • putAll

        public void putAll​(@NotNull
                           Map<String,​String> fromMap)
        Allows to add map of parameters into the backing map
        Specified by:
        putAll in interface MapParametersProvider
        Parameters:
        fromMap - the map to copy parameters from
      • size

        public int size()
        Description copied from interface: ParametersProvider
        Returns the number of parameters in this parameters provider. This is the size of the map returned by getAll method.
        Specified by:
        size in interface ParametersProvider
      • getAll

        public Map<String,​String> getAll()
        Description copied from interface: ParametersProvider
        Allows 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:
        getAll in interface ParametersProvider
        Returns:
        copy of the backed data