Home | History | Annotate | Download | only in jline
      1 /*
      2  * Copyright (c) 2002-2007, Marc Prud'hommeaux. All rights reserved.
      3  *
      4  * This software is distributable under the BSD license. See the terms of the
      5  * BSD license in the documentation provided with this software.
      6  */
      7 package jline;
      8 
      9 import java.util.*;
     10 
     11 /**
     12  *  <p>
     13  *  A completor that does nothing. Useful as the last item in an
     14  *  {@link ArgumentCompletor}.
     15  *  </p>
     16  *
     17  *  @author  <a href="mailto:mwp1 (at) cornell.edu">Marc Prud'hommeaux</a>
     18  */
     19 public class NullCompletor implements Completor {
     20     /**
     21      *  Returns -1 always, indicating that the the buffer is never
     22      *  handled.
     23      */
     24     public int complete(final String buffer, int cursor, List candidates) {
     25         return -1;
     26     }
     27 }
     28