class Client {

  public Index[] getIndices() {
    String[] indexNames = this.configuration.getStrings(INDEXES_CONF_KEY);
    int arrayLength = indexNames == null ? 0 : indexNames.length;
    Index[] indices = new Index[arrayLength];
    for (int i = 0; i < arrayLength; i++) {
      String name = indexNames[i];
      Class<?> indexClass = configuration.getClass(indexClassConfKey(name),
          null);
      Configuration indexConf = ConfUtils.unpackConfigurationInPrefix(
          indexConfPrefix(name), configuration);
      Index index;
      try {
        index = Index.class.cast(indexClass.newInstance());
      } catch (InstantiationException e) {
        throw new RuntimeException(e);
      } catch (IllegalAccessException e) {
        throw new RuntimeException(e);
      }
      index.setConf(indexConf);
      indices[i] = index;
    }
    return indices;
  }

  public  Client(Configuration conf);

}