All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.infinispan.cli.completers.ConnectorCompleter Maven / Gradle / Ivy

package org.infinispan.cli.completers;

import java.io.IOException;
import java.util.Collection;
import java.util.Collections;

import org.infinispan.cli.Context;

/**
 * A {@link org.aesh.command.completer.OptionCompleter} for protocol connectors.
 *
 * @author Tristan Tarrant
 * @since 12.1
 */
public class ConnectorCompleter extends ListCompleter {
   @Override
   Collection getAvailableItems(Context context) throws IOException {
      try {
         return context.getConnection().getConnectorNames();
      } catch (IOException e) {
         return Collections.emptyList();
      }
   }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy