Class CompositeParametersProviderImpl

    • Constructor Detail

      • CompositeParametersProviderImpl

        public CompositeParametersProviderImpl()
    • Method Detail

      • appendParametersProvider

        public void appendParametersProvider​(@NotNull
                                             ParametersProvider provider)
        Appends a provider to the end of providers list. Note that the values in the providers appended earlier will take precedence.
        Specified by:
        appendParametersProvider in interface CompositeParametersProvider
        Parameters:
        provider - the provider to append
      • get

        @Nullable
        public String get​(@NotNull
                          String key)
        Looks up a value corresponding to the key passed. The providers are looked up in the order they were appended. So, if the key occurs in two providers, the one appended earlier will be used to get the value.
        Specified by:
        get in interface ParametersProvider
        Parameters:
        key - key to look for
        Returns:
        the value corresponding to the key passed from the first matching held provider
      • 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:
        the map which has the same key-value pairs as the the provider