Exemplo n.º 1
0
  private final void setTypeComparatorFactory(
      TypeComparatorFactory<?> factory, String classNameKey, String parametersPrefix) {
    // sanity check the factory type
    InstantiationUtil.checkForInstantiation(factory.getClass());

    // store the type
    this.config.setString(classNameKey, factory.getClass().getName());
    // store the parameters
    final DelegatingConfiguration parameters =
        new DelegatingConfiguration(this.config, parametersPrefix);
    factory.writeParametersToConfig(parameters);
  }