Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## mars.venus.editors.jeditsyntax
Class PopupHelpItem

    java.lang.Object
      mars.venus.editors.jeditsyntax.PopupHelpItem

    public class PopupHelpItem

extends Object

Handly little class to contain help information for a popupMenu or tool tip item.

Constructor Summary
`PopupHelpItem(String tokenText, String example, String description)` Create popup help item, where match is result of an exact-match search.
`PopupHelpItem(String tokenText, String example, String description, boolean exact)` Create popup help item.

Method Summary
`String` | `getDescription()`
`boolean` | `getExact()` Determines whether match occurred in an exact-match or prefix-match search.
`String` | `getExample()`
`int` | `getExampleLength()`
`String` | `getExamplePaddedToLength(int length)`
`String` | `getTokenText()` The document text that mached this item
`static int` | `maxExampleLength(ArrayList matches)`
`void` | `setDescription(String description)`
`void` | `setExample(String example)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### PopupHelpItem

    public PopupHelpItem(String tokenText,
                         String example,
                         String description,
                         boolean exact)

  Create popup help item. This is created as result of either an exact-match or prefix-match search. Note that prefix-match search includes exact as well as partial matches.

  Parameters:
    `tokenText` - The document text that matched
    `example` - An example instruction
    `description` - A textual description of the instruction
    `exact` - True if match occurred as result of exact-match search, false otherwise.

### PopupHelpItem

    public PopupHelpItem(String tokenText,
                         String example,
                         String description)

  Create popup help item, where match is result of an exact-match search.

  Parameters:
    `tokenText` - The document text that matched
    `example` - An example instruction
    `description` - A textual description of the instruction

Method Detail

### getTokenText

    public String getTokenText()

  The document text that mached this item

### getExample

    public String getExample()

### getDescription

    public String getDescription()

### getExact

    public boolean getExact()

  Determines whether match occurred in an exact-match or prefix-match search. Note this can return false even if the match is exact because prefix-match also includes exact match results. E.g. prefix match on "lw" will match both "lwl" and "lw".

  Returns:
    True if exact-match search, false otherwise.

### getExampleLength

    public int getExampleLength()

### getExamplePaddedToLength

    public String getExamplePaddedToLength(int length)

### setExample

    public void setExample(String example)

### setDescription

    public void setDescription(String description)

### maxExampleLength

    public static int maxExampleLength(ArrayList matches)

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD