ArgumentCompletor.AbstractArgumentDelimiter
Date: 2015-12-09

jline

## Class ArgumentCompletor.AbstractArgumentDelimiter

- java.lang.Object
- - jline.ArgumentCompletor.AbstractArgumentDelimiter

- All Implemented Interfaces:
    ArgumentCompletor.ArgumentDelimiter
  Direct Known Subclasses:
    ArgumentCompletor.WhitespaceArgumentDelimiter
  Enclosing class:
    ArgumentCompletor

      public abstract static class ArgumentCompletor.AbstractArgumentDelimiter
      extends java.lang.Object
      implements ArgumentCompletor.ArgumentDelimiter

  Abstract implementation of a delimiter that uses the `isDelimiter(java.lang.String, int)` method to determine if a particular character should be used as a delimiter.
  Author:
    Marc Prud'hommeaux

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ArgumentCompletor.AbstractArgumentDelimiter()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `ArgumentCompletor.ArgumentList` | `delimit(java.lang.String buffer, int cursor)` Break the specified buffer into individual tokens that can be completed on their own.
    `char[]` | `getEscapeChars()`
    `char[]` | `getQuoteChars()`
    `boolean` | `isDelimiter(java.lang.String buffer, int pos)` Returns true if the specified character is a whitespace parameter.
    `abstract boolean` | `isDelimiterChar(java.lang.String buffer, int pos)` Returns true if the character at the specified position if a delimiter.
    `boolean` | `isEscaped(java.lang.String buffer, int pos)`
    `boolean` | `isQuoted(java.lang.String buffer, int pos)`
    `void` | `setEscapeChars(char[] escapeChars)`
    `void` | `setQuoteChars(char[] quoteChars)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ArgumentCompletor.AbstractArgumentDelimiter

          public ArgumentCompletor.AbstractArgumentDelimiter()

  - ### Method Detail

    - #### setQuoteChars

          public void setQuoteChars(char[] quoteChars)

    - #### getQuoteChars

          public char[] getQuoteChars()

    - #### setEscapeChars

          public void setEscapeChars(char[] escapeChars)

    - #### getEscapeChars

          public char[] getEscapeChars()

    - #### delimit

          public ArgumentCompletor.ArgumentList delimit(java.lang.String buffer,
                                               int cursor)

      Description copied from interface: `ArgumentCompletor.ArgumentDelimiter`
      Break the specified buffer into individual tokens that can be completed on their own.
      Specified by:
        `delimit` in interface `ArgumentCompletor.ArgumentDelimiter`
      Parameters:
        `buffer` - the buffer to split
        `cursor` - the current position of the cursor in the buffer
      Returns:
        the tokens

    - #### isDelimiter

          public boolean isDelimiter(java.lang.String buffer,
                            int pos)

      Returns true if the specified character is a whitespace parameter. Check to ensure that the character is not escaped by any of `getQuoteChars()`, and is not escaped by ant of the `getEscapeChars()`, and returns true from `isDelimiterChar(java.lang.String, int)`.
      Specified by:
        `isDelimiter` in interface `ArgumentCompletor.ArgumentDelimiter`
      Parameters:
        `buffer` - the complete command buffer
        `pos` - the index of the character in the buffer
      Returns:
        true if the character should be a delimiter

    - #### isQuoted

          public boolean isQuoted(java.lang.String buffer,
                         int pos)

    - #### isEscaped

          public boolean isEscaped(java.lang.String buffer,
                          int pos)

    - #### isDelimiterChar

          public abstract boolean isDelimiterChar(java.lang.String buffer,
                                int pos)

      Returns true if the character at the specified position if a delimiter. This method will only be called if the character is not enclosed in any of the `getQuoteChars()`, and is not escaped by ant of the `getEscapeChars()`. To perform escaping manually, override `isDelimiter(java.lang.String, int)` instead.