org.sonatype.gshell.command.registry
Class CommandNameCompleter

java.lang.Object
  extended by org.sonatype.gshell.command.registry.CommandNameCompleter
All Implemented Interfaces:
jline.console.completer.Completer

@Singleton
public class CommandNameCompleter
extends Object
implements jline.console.completer.Completer

Completer for command names. Keeps up to date automatically by handling command-related events.

Since:
2.5
Author:
Jason Dillon

Constructor Summary
CommandNameCompleter(EventManager events, CommandRegistry commands)
           
 
Method Summary
 int complete(String buffer, int cursor, List<CharSequence> candidates)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CommandNameCompleter

@Inject
public CommandNameCompleter(EventManager events,
                                   CommandRegistry commands)
Method Detail

complete

public int complete(String buffer,
                    int cursor,
                    List<CharSequence> candidates)
Specified by:
complete in interface jline.console.completer.Completer


Copyright © 2008-2011 Sonatype. All Rights Reserved.