Interface NBConfigModel

All Known Implementing Classes:
ConfigModel

public interface NBConfigModel

This configuration model describes what is valid to submit for configuration for a given configurable object. Once this is provided by a configurable element, it is used internally by NoSQLBench to ensure that only valid configuration are given to newly built objects.

It is conventional to put the config model at the bottom of any implementing class for quick reference.

  • Method Details

    • getNamedParams

      Map<String,Param<?>> getNamedParams()
    • getParams

      List<Param<?>> getParams()
    • getOf

      Class<?> getOf()
    • assertValidConfig

      void assertValidConfig(Map<String,?> config)
    • assertNoConflicts

      void assertNoConflicts(Map<String,?> config, String type)
    • apply

      NBConfiguration apply(Map<String,?> config)
    • getParam

      <V> Param<V> getParam(String... name)
    • extractConfig

      NBConfiguration extractConfig(Map<String,?> sharedConfig)
      Extract the fields from the shared config into a separate config, removing those that are defined in this model and leaving extraneous config fields in the provided model. This method mutates the map that is provided.
      Parameters:
      sharedConfig - A config map which can provide fields to multiple models
      Returns:
      A new configuration for the extracted fields only.
    • extractConfig

      NBConfiguration extractConfig(NBConfiguration cfg)
      Extract the fields from the shared config into a separate config, removing those that are defined in this model and leaving extraneous config fields in the provided model. This method mutates the map that is provided.
      Parameters:
      cfg - A config map which can provide fields to multiple models
      Returns:
      A new configuration for the extracted fields only.
    • matchConfig

      NBConfiguration matchConfig(NBConfiguration cfg)
    • matchConfig

      NBConfiguration matchConfig(Map<String,?> sharedConfig)
    • add

      NBConfigModel add(NBConfigModel otherModel)
    • log

      void log()