Groovy 2.2.0

org.codehaus.groovy.tools.shell.completion
[Groovy] Class FileNameCompleter

java.lang.Object
  org.codehaus.groovy.tools.shell.completion.FileNameCompleter
All Implemented Interfaces:
Completer

class FileNameCompleter

PATCHED copy from jline2.10, included https://github.com/jline/jline2/pull/88 https://github.com/jline/jline2/issues/90 A file name completer takes the buffer and issues a list of potential completions.

This completer tries to behave as similar as possible to bash's file name completion (using GNU readline) with the following exceptions:

Authors:
Marc Prud'hommeaux
Jason Dillon
Since:
2.3


Constructor Summary
FileNameCompleter()

FileNameCompleter(boolean blankSuffix)

 
Method Summary
int complete(String buffer, int cursor, List candidates)

protected File getUserDir()

protected File getUserHome()

protected int matchFiles(String buffer, String translated, File[] files, List candidates)

protected CharSequence render(File file, CharSequence name)

protected String separator()

 
Methods inherited from class Object
wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll
 

Constructor Detail

FileNameCompleter

FileNameCompleter()


FileNameCompleter

FileNameCompleter(boolean blankSuffix)


 
Method Detail

complete

int complete(String buffer, int cursor, List candidates)


getUserDir

protected File getUserDir()


getUserHome

protected File getUserHome()


matchFiles

protected int matchFiles(String buffer, String translated, File[] files, List candidates)


render

protected CharSequence render(File file, CharSequence name)


separator

protected String separator()


 

Copyright © 2003-2013 The Codehaus. All rights reserved.