Interface LineReader
-
- All Known Implementing Classes:
LineReaderImpl
public interface LineReaderRead lines from the console, with input editing.Thread safety
TheLineReaderimplementations are not thread safe, thus you should not attempt to use a single reader in several threads. Any attempt to call one of thereadLinecall while one is already executing in a different thread will immediately result in anIllegalStateExceptionbeing thrown. Other calls may lead to unknown behaviors. There is one exception though: users are allowed to callprintAbove(String)orprintAbove(AttributedString)at any time to allow text to be printed above the current prompt.Prompt strings
It is traditional for an interactive console-based program to print a short prompt string to signal that the user is expected to type a command. JLine supports 3 kinds of prompt string:- The normal prompt at the start (left) of the initial line of a command.
- An optional right prompt at the right border of the initial line.
- A start (left) prompt for continuation lines. I.e. the lines after the first line of a multi-line command.
All of these are specified with prompt templates, which are similar to
The pattern may include ANSI escapes. It may include these template markers:printfformat strings, using the character'%'to indicate special functionality.%N- A line number. This is the sum of
getLineNumber()and a counter starting with 1 for the first continuation line. %M- A short word explaining what is "missing". This is supplied from
the
EOFError.getMissing()method, if provided. Defaults to an empty string. %nPc- Insert padding at this position, repeating the following character c as needed to bring the total prompt column width as specified by the digits n.
%Pc- As before, but use width from the initial prompt.
%%- A literal
'%'. %{%}- Text between a
%{...%}pair is printed as part of a prompt, but not interpreted by JLine (except that'%'-escapes are processed). The text is assumed to take zero columns (not move the cursor). If it changes the style, you're responsible for changing it back. Standard ANSI escape sequences do not need to be within a%{...%}pair (though can be) since JLine knows how to deal with them. However, these delimiters are needed for unusual non-standard escape sequences.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classLineReader.Optionstatic classLineReader.RegionTypestatic classLineReader.SuggestionType
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringACCEPT_AND_HOLDstatic java.lang.StringACCEPT_AND_INFER_NEXT_HISTORYstatic java.lang.StringACCEPT_LINEstatic java.lang.StringACCEPT_LINE_AND_DOWN_HISTORYstatic java.lang.StringAMBIGUOUS_BINDINGTimeout for ambiguous key sequences.static java.lang.StringARGUMENT_BASEstatic java.lang.StringBACKWARD_CHARstatic java.lang.StringBACKWARD_DELETE_CHARstatic java.lang.StringBACKWARD_DELETE_WORDstatic java.lang.StringBACKWARD_KILL_LINEstatic java.lang.StringBACKWARD_KILL_WORDstatic java.lang.StringBACKWARD_WORDstatic java.lang.StringBEEPstatic java.lang.StringBEGIN_PASTEstatic java.lang.StringBEGINNING_OF_BUFFER_OR_HISTORYstatic java.lang.StringBEGINNING_OF_HISTORYstatic java.lang.StringBEGINNING_OF_LINEstatic java.lang.StringBEGINNING_OF_LINE_HISTstatic java.lang.StringBELL_STYLEstatic java.lang.StringBIND_TTY_SPECIAL_CHARSstatic java.lang.StringBLINK_MATCHING_PARENstatic java.lang.StringCALLBACK_FINISHstatic java.lang.StringCALLBACK_INITstatic java.lang.StringCALLBACK_KEYMAPstatic java.lang.StringCAPITALIZE_WORDstatic java.lang.StringCHARACTER_SEARCHstatic java.lang.StringCHARACTER_SEARCH_BACKWARDstatic java.lang.StringCLEARstatic java.lang.StringCLEAR_SCREENstatic java.lang.StringCOMMENT_BEGINstatic java.lang.StringCOMPLETE_PREFIXstatic java.lang.StringCOMPLETE_WORDstatic java.lang.StringCOMPLETION_STYLE_BACKGROUNDCompletion style for displaying the liststatic java.lang.StringCOMPLETION_STYLE_DESCRIPTIONCompletion style for displaying the candidate descriptionstatic java.lang.StringCOMPLETION_STYLE_GROUPCompletion style for displaying groups namestatic java.lang.StringCOMPLETION_STYLE_LIST_BACKGROUNDstatic java.lang.StringCOMPLETION_STYLE_LIST_DESCRIPTIONstatic java.lang.StringCOMPLETION_STYLE_LIST_GROUPstatic java.lang.StringCOMPLETION_STYLE_LIST_SELECTIONstatic java.lang.StringCOMPLETION_STYLE_LIST_STARTINGstatic java.lang.StringCOMPLETION_STYLE_SELECTIONCompletion style for displaying the current selected itemstatic java.lang.StringCOMPLETION_STYLE_STARTINGCompletion style for displaying the matching part of candidatesstatic java.lang.StringCOPY_PREV_WORDstatic java.lang.StringCOPY_REGION_AS_KILLstatic java.lang.StringDELETE_CHARstatic java.lang.StringDELETE_CHAR_OR_LISTstatic java.lang.StringDELETE_WORDstatic java.lang.StringDIGIT_ARGUMENTstatic java.lang.StringDISABLE_COMPLETIONstatic java.lang.StringDISABLE_HISTORYstatic java.lang.StringDO_LOWERCASE_VERSIONstatic java.lang.StringDOWN_CASE_WORDstatic java.lang.StringDOWN_HISTORYstatic java.lang.StringDOWN_LINEstatic java.lang.StringDOWN_LINE_OR_HISTORYstatic java.lang.StringDOWN_LINE_OR_SEARCHstatic java.lang.StringDUMBstatic java.lang.StringEDIT_AND_EXECUTE_COMMANDstatic java.lang.StringEDITING_MODEstatic java.lang.StringEMACSstatic java.lang.StringEMACS_BACKWARD_WORDstatic java.lang.StringEMACS_EDITING_MODEstatic java.lang.StringEMACS_FORWARD_WORDstatic java.lang.StringEND_OF_BUFFER_OR_HISTORYstatic java.lang.StringEND_OF_HISTORYstatic java.lang.StringEND_OF_LINEstatic java.lang.StringEND_OF_LINE_HISTstatic java.lang.StringERRORSNumber of matching errors that are accepted by the completion matcherstatic java.lang.StringEXCHANGE_POINT_AND_MARKstatic java.lang.StringEXECUTE_NAMED_CMDstatic java.lang.StringEXPAND_HISTORYstatic java.lang.StringEXPAND_OR_COMPLETEstatic java.lang.StringEXPAND_OR_COMPLETE_PREFIXstatic java.lang.StringEXPAND_WORDstatic java.lang.StringFEATURES_MAX_BUFFER_SIZEMax buffer size for advanced features.static java.lang.StringFOCUS_INstatic java.lang.StringFOCUS_OUTstatic java.lang.StringFORWARD_CHARstatic java.lang.StringFORWARD_WORDstatic java.lang.StringFRESH_LINEstatic java.lang.StringHISTORY_BEGINNING_SEARCH_BACKWARDstatic java.lang.StringHISTORY_BEGINNING_SEARCH_FORWARDstatic java.lang.StringHISTORY_FILEFile system history path.static java.lang.StringHISTORY_FILE_SIZENumber of history items to keep in the history file.static java.lang.StringHISTORY_IGNOREColon separated list of patterns that will not be saved in history.static java.lang.StringHISTORY_INCREMENTAL_PATTERN_SEARCH_BACKWARDstatic java.lang.StringHISTORY_INCREMENTAL_PATTERN_SEARCH_FORWARDstatic java.lang.StringHISTORY_INCREMENTAL_SEARCH_BACKWARDstatic java.lang.StringHISTORY_INCREMENTAL_SEARCH_FORWARDstatic java.lang.StringHISTORY_SEARCH_BACKWARDstatic java.lang.StringHISTORY_SEARCH_FORWARDstatic java.lang.StringHISTORY_SIZENumber of history items to keep in memory.static java.lang.StringINDENTATIONNew line automatic indentation after opening/closing bracket.static java.lang.StringINFER_NEXT_HISTORYstatic java.lang.StringINPUT_RC_FILE_NAMEName of inputrc to read at line reader creation time.static java.lang.StringINSERT_CLOSE_CURLYstatic java.lang.StringINSERT_CLOSE_PARENstatic java.lang.StringINSERT_CLOSE_SQUAREstatic java.lang.StringINSERT_COMMENTstatic java.lang.StringINSERT_LAST_WORDstatic java.lang.StringKEYMAPstatic java.lang.StringKILL_BUFFERstatic java.lang.StringKILL_LINEstatic java.lang.StringKILL_REGIONstatic java.lang.StringKILL_WHOLE_LINEstatic java.lang.StringKILL_WORDstatic java.lang.StringLINE_OFFSETWhen in multiline edit mode, this variable can be used to offset the line number displayed.static java.lang.StringLIST_CHOICESstatic java.lang.StringLIST_EXPANDstatic java.lang.StringLIST_MAXtab completion: if candidates are more than list-max a question will be asked before displaying themstatic java.lang.StringMAGIC_SPACEstatic java.lang.StringMAINstatic java.lang.StringMAX_REPEAT_COUNTMax number of times a command can be repeated.static java.lang.StringMENUstatic java.lang.StringMENU_COMPLETEstatic java.lang.StringMENU_EXPAND_OR_COMPLETEstatic java.lang.StringMENU_LIST_MAXtab completion: if candidates are less than menu-list-max they are displayed in a list below the field to be completedstatic java.lang.StringMENU_SELECTstatic java.lang.StringMOUSEstatic java.lang.StringNEG_ARGUMENTstatic java.lang.StringORIGINAL_GROUP_NAMEProperty for the "original" group namestatic java.lang.StringOTHERS_GROUP_NAMEProperty for the "others" group namestatic java.lang.StringOVERWRITE_MODEstatic java.lang.StringPREFER_VISIBLE_BELLstatic java.lang.StringPROP_SUPPORT_PARSEDLINESystem property that can be set to avoid a warning being logged when using a Parser which does not returnCompletingParsedLineobjects.static java.lang.StringPUT_REPLACE_SELECTIONstatic java.lang.StringQUOTED_INSERTstatic java.lang.StringREAD_COMMANDstatic java.lang.StringRECURSIVE_EDITstatic java.lang.StringREDISPLAYstatic java.lang.StringREDOstatic java.lang.StringREDRAW_LINEstatic java.lang.StringREMOVE_SUFFIX_CHARSstatic java.lang.StringREVERSE_MENU_COMPLETEstatic java.lang.StringSAFEstatic java.lang.StringSEARCH_TERMINATORSstatic java.lang.StringSECONDARY_PROMPT_PATTERNSet the template for prompts for secondary (continuation) lines.static java.lang.StringSELF_INSERTstatic java.lang.StringSELF_INSERT_UNMETAstatic java.lang.StringSEND_BREAKstatic java.lang.StringSET_LOCAL_HISTORYstatic java.lang.StringSET_MARK_COMMANDstatic java.lang.StringSPELL_WORDstatic java.lang.StringSPLIT_UNDOstatic java.lang.StringSUGGESTIONS_MIN_BUFFER_SIZEMin buffer size for tab auto-suggestions.static java.lang.StringSYSTEM_PROPERTY_PREFIXPrefix to automatically delegate variables to system propertiesstatic java.lang.StringTAB_WIDTHNumber of spaces to display a tabulation, the default is 4.static java.lang.StringTRANSPOSE_CHARSstatic java.lang.StringTRANSPOSE_WORDSstatic java.lang.StringUNDEFINED_KEYstatic java.lang.StringUNDOstatic java.lang.StringUNIVERSAL_ARGUMENTstatic java.lang.StringUP_CASE_WORDstatic java.lang.StringUP_HISTORYstatic java.lang.StringUP_LINEstatic java.lang.StringUP_LINE_OR_HISTORYstatic java.lang.StringUP_LINE_OR_SEARCHstatic java.lang.StringVI_ADD_EOLstatic java.lang.StringVI_ADD_NEXTstatic java.lang.StringVI_BACKWARD_BLANK_WORDstatic java.lang.StringVI_BACKWARD_BLANK_WORD_ENDstatic java.lang.StringVI_BACKWARD_CHARstatic java.lang.StringVI_BACKWARD_DELETE_CHARstatic java.lang.StringVI_BACKWARD_KILL_WORDstatic java.lang.StringVI_BACKWARD_WORDstatic java.lang.StringVI_BACKWARD_WORD_ENDstatic java.lang.StringVI_BEGINNING_OF_LINEstatic java.lang.StringVI_CHANGEstatic java.lang.StringVI_CHANGE_EOLstatic java.lang.StringVI_CHANGE_WHOLE_LINEstatic java.lang.StringVI_CMD_MODEstatic java.lang.StringVI_DELETEstatic java.lang.StringVI_DELETE_CHARstatic java.lang.StringVI_DIGIT_OR_BEGINNING_OF_LINEstatic java.lang.StringVI_DOWN_LINE_OR_HISTORYstatic java.lang.StringVI_END_OF_LINEstatic java.lang.StringVI_FETCH_HISTORYstatic java.lang.StringVI_FIND_NEXT_CHARstatic java.lang.StringVI_FIND_NEXT_CHAR_SKIPstatic java.lang.StringVI_FIND_PREV_CHARstatic java.lang.StringVI_FIND_PREV_CHAR_SKIPstatic java.lang.StringVI_FIRST_NON_BLANKstatic java.lang.StringVI_FORWARD_BLANK_WORDstatic java.lang.StringVI_FORWARD_BLANK_WORD_ENDstatic java.lang.StringVI_FORWARD_CHARstatic java.lang.StringVI_FORWARD_WORDstatic java.lang.StringVI_FORWARD_WORD_ENDstatic java.lang.StringVI_GOTO_COLUMNstatic java.lang.StringVI_HISTORY_SEARCH_BACKWARDstatic java.lang.StringVI_HISTORY_SEARCH_FORWARDstatic java.lang.StringVI_INSERTstatic java.lang.StringVI_INSERT_BOLstatic java.lang.StringVI_INSERT_COMMENTstatic java.lang.StringVI_JOINstatic java.lang.StringVI_KILL_EOLstatic java.lang.StringVI_KILL_LINEstatic java.lang.StringVI_MATCH_BRACKETstatic java.lang.StringVI_OPEN_LINE_ABOVEstatic java.lang.StringVI_OPEN_LINE_BELOWstatic java.lang.StringVI_OPER_SWAP_CASEstatic java.lang.StringVI_PUT_AFTERstatic java.lang.StringVI_PUT_BEFOREstatic java.lang.StringVI_QUOTED_INSERTstatic java.lang.StringVI_REPEAT_CHANGEstatic java.lang.StringVI_REPEAT_FINDstatic java.lang.StringVI_REPEAT_SEARCHstatic java.lang.StringVI_REPLACEstatic java.lang.StringVI_REPLACE_CHARSstatic java.lang.StringVI_REV_REPEAT_FINDstatic java.lang.StringVI_REV_REPEAT_SEARCHstatic java.lang.StringVI_SET_BUFFERstatic java.lang.StringVI_SUBSTITUTEstatic java.lang.StringVI_SWAP_CASEstatic java.lang.StringVI_UNDO_CHANGEstatic java.lang.StringVI_UP_LINE_OR_HISTORYstatic java.lang.StringVI_YANKstatic java.lang.StringVI_YANK_EOLstatic java.lang.StringVI_YANK_WHOLE_LINEstatic java.lang.StringVICMDstatic java.lang.StringVIINSstatic java.lang.StringVIOPPstatic java.lang.StringVISUALstatic java.lang.StringVISUAL_LINE_MODEstatic java.lang.StringVISUAL_MODEstatic java.lang.StringWHAT_CURSOR_POSITIONstatic java.lang.StringWORDCHARSstatic java.lang.StringYANKstatic java.lang.StringYANK_POP
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidaddCommandsInBuffer(java.util.Collection<java.lang.String> commands)Adds a collection of commands to the input buffer for execution.voidcallWidget(java.lang.String name)Calls a widget by name.java.util.Map<java.lang.String,KeyMap<Binding>>defaultKeyMaps()Returns the default key maps used by the LineReader.default voideditAndAddInBuffer(java.io.File file)Opens a file in an external editor and adds its contents to the input buffer.voideditAndAddInBuffer(java.nio.file.Path file)Opens a file in an external editor and adds its contents to the input buffer.java.lang.StringgetAppName()Returns the application name associated with this LineReader.LineReader.SuggestionTypegetAutosuggestion()Returns the current auto-suggestion type.BuffergetBuffer()Returns the current line buffer.java.util.Map<java.lang.String,Widget>getBuiltinWidgets()Returns a map of all built-in widgets provided by the LineReader.ExpandergetExpander()Returns the expander associated with this LineReader.HighlightergetHighlighter()Returns the highlighter associated with this LineReader.HistorygetHistory()Returns the history associated with this LineReader.java.lang.StringgetKeyMap()Returns the name of the currently active key map.java.util.Map<java.lang.String,KeyMap<Binding>>getKeyMaps()Returns all key maps registered with this LineReader.KeyMap<Binding>getKeys()Returns the currently active key map.java.lang.StringgetLastBinding()Returns the last key binding that was processed.ParsedLinegetParsedLine()Returns the parsed representation of the current line.ParsergetParser()Returns the parser associated with this LineReader.LineReader.RegionTypegetRegionActive()Returns the type of the currently active region selection.intgetRegionMark()Returns the mark position of the currently active region.java.lang.StringgetSearchTerm()Returns the current search term when in history search mode.java.lang.StringgetTailTip()Returns the current tail tip text.TerminalgetTerminal()Returns the terminal associated with this LineReader.java.lang.ObjectgetVariable(java.lang.String name)Returns the value of a variable.java.util.Map<java.lang.String,java.lang.Object>getVariables()Returns a map of all variables set in the LineReader.java.util.Map<java.lang.String,Widget>getWidgets()Returns a map of all widgets registered with this LineReader.booleanisReading()Check if a thread is currently in areadLine()call.booleanisSet(LineReader.Option option)Checks if an option is set.LineReaderoption(LineReader.Option option, boolean value)Sets an option in the LineReader and returns the LineReader for method chaining.voidprintAbove(java.lang.String str)Prints a line above the prompt and redraw everything.voidprintAbove(AttributedString str)Prints a string before the prompt and redraw everything.java.lang.StringreadLine()Read the next line and return the contents of the buffer.java.lang.StringreadLine(java.lang.Character mask)Read the next line with the specified character mask.java.lang.StringreadLine(java.lang.String prompt)Read the next line with the specified prompt.java.lang.StringreadLine(java.lang.String prompt, java.lang.Character mask)Read a line from the inInputStream, and return the line (without any trailing newlines).java.lang.StringreadLine(java.lang.String prompt, java.lang.Character mask, java.lang.String buffer)Read a line from the inInputStream, and return the line (without any trailing newlines).java.lang.StringreadLine(java.lang.String prompt, java.lang.String rightPrompt, java.lang.Character mask, java.lang.String buffer)Read a line from the inInputStream, and return the line (without any trailing newlines).java.lang.StringreadLine(java.lang.String prompt, java.lang.String rightPrompt, MaskingCallback maskingCallback, java.lang.String buffer)Read a line from the inInputStream, and return the line (without any trailing newlines).MouseEventreadMouseEvent()Read a mouse event when theInfoCmp.Capability.key_mousesequence has just been read on the input stream.voidrunMacro(java.lang.String macro)Push back a key sequence that will be later consumed by the line reader.voidsetAutosuggestion(LineReader.SuggestionType type)Sets the type of auto-suggestion to use.booleansetKeyMap(java.lang.String name)Sets the active key map by name.voidsetOpt(LineReader.Option option)Sets an option to true.voidsetTailTip(java.lang.String tailTip)Sets the tail tip text.voidsetVariable(java.lang.String name, java.lang.Object value)Sets a variable in the LineReader.voidunsetOpt(LineReader.Option option)Sets an option to false.LineReadervariable(java.lang.String name, java.lang.Object value)Sets a variable in the LineReader and returns the LineReader for method chaining.voidzeroOut()Clears any internal buffers and sensitive data.
-
-
-
Field Detail
-
PROP_SUPPORT_PARSEDLINE
static final java.lang.String PROP_SUPPORT_PARSEDLINE
System property that can be set to avoid a warning being logged when using a Parser which does not returnCompletingParsedLineobjects.- See Also:
- Constant Field Values
-
CALLBACK_INIT
static final java.lang.String CALLBACK_INIT
- See Also:
- Constant Field Values
-
CALLBACK_FINISH
static final java.lang.String CALLBACK_FINISH
- See Also:
- Constant Field Values
-
CALLBACK_KEYMAP
static final java.lang.String CALLBACK_KEYMAP
- See Also:
- Constant Field Values
-
ACCEPT_AND_INFER_NEXT_HISTORY
static final java.lang.String ACCEPT_AND_INFER_NEXT_HISTORY
- See Also:
- Constant Field Values
-
ACCEPT_AND_HOLD
static final java.lang.String ACCEPT_AND_HOLD
- See Also:
- Constant Field Values
-
ACCEPT_LINE
static final java.lang.String ACCEPT_LINE
- See Also:
- Constant Field Values
-
ACCEPT_LINE_AND_DOWN_HISTORY
static final java.lang.String ACCEPT_LINE_AND_DOWN_HISTORY
- See Also:
- Constant Field Values
-
ARGUMENT_BASE
static final java.lang.String ARGUMENT_BASE
- See Also:
- Constant Field Values
-
BACKWARD_CHAR
static final java.lang.String BACKWARD_CHAR
- See Also:
- Constant Field Values
-
BACKWARD_DELETE_CHAR
static final java.lang.String BACKWARD_DELETE_CHAR
- See Also:
- Constant Field Values
-
BACKWARD_DELETE_WORD
static final java.lang.String BACKWARD_DELETE_WORD
- See Also:
- Constant Field Values
-
BACKWARD_KILL_LINE
static final java.lang.String BACKWARD_KILL_LINE
- See Also:
- Constant Field Values
-
BACKWARD_KILL_WORD
static final java.lang.String BACKWARD_KILL_WORD
- See Also:
- Constant Field Values
-
BACKWARD_WORD
static final java.lang.String BACKWARD_WORD
- See Also:
- Constant Field Values
-
BEEP
static final java.lang.String BEEP
- See Also:
- Constant Field Values
-
BEGINNING_OF_BUFFER_OR_HISTORY
static final java.lang.String BEGINNING_OF_BUFFER_OR_HISTORY
- See Also:
- Constant Field Values
-
BEGINNING_OF_HISTORY
static final java.lang.String BEGINNING_OF_HISTORY
- See Also:
- Constant Field Values
-
BEGINNING_OF_LINE
static final java.lang.String BEGINNING_OF_LINE
- See Also:
- Constant Field Values
-
BEGINNING_OF_LINE_HIST
static final java.lang.String BEGINNING_OF_LINE_HIST
- See Also:
- Constant Field Values
-
CAPITALIZE_WORD
static final java.lang.String CAPITALIZE_WORD
- See Also:
- Constant Field Values
-
CHARACTER_SEARCH
static final java.lang.String CHARACTER_SEARCH
- See Also:
- Constant Field Values
-
CHARACTER_SEARCH_BACKWARD
static final java.lang.String CHARACTER_SEARCH_BACKWARD
- See Also:
- Constant Field Values
-
CLEAR
static final java.lang.String CLEAR
- See Also:
- Constant Field Values
-
CLEAR_SCREEN
static final java.lang.String CLEAR_SCREEN
- See Also:
- Constant Field Values
-
COMPLETE_PREFIX
static final java.lang.String COMPLETE_PREFIX
- See Also:
- Constant Field Values
-
COMPLETE_WORD
static final java.lang.String COMPLETE_WORD
- See Also:
- Constant Field Values
-
COPY_PREV_WORD
static final java.lang.String COPY_PREV_WORD
- See Also:
- Constant Field Values
-
COPY_REGION_AS_KILL
static final java.lang.String COPY_REGION_AS_KILL
- See Also:
- Constant Field Values
-
DELETE_CHAR
static final java.lang.String DELETE_CHAR
- See Also:
- Constant Field Values
-
DELETE_CHAR_OR_LIST
static final java.lang.String DELETE_CHAR_OR_LIST
- See Also:
- Constant Field Values
-
DELETE_WORD
static final java.lang.String DELETE_WORD
- See Also:
- Constant Field Values
-
DIGIT_ARGUMENT
static final java.lang.String DIGIT_ARGUMENT
- See Also:
- Constant Field Values
-
DO_LOWERCASE_VERSION
static final java.lang.String DO_LOWERCASE_VERSION
- See Also:
- Constant Field Values
-
DOWN_CASE_WORD
static final java.lang.String DOWN_CASE_WORD
- See Also:
- Constant Field Values
-
DOWN_HISTORY
static final java.lang.String DOWN_HISTORY
- See Also:
- Constant Field Values
-
DOWN_LINE
static final java.lang.String DOWN_LINE
- See Also:
- Constant Field Values
-
DOWN_LINE_OR_HISTORY
static final java.lang.String DOWN_LINE_OR_HISTORY
- See Also:
- Constant Field Values
-
DOWN_LINE_OR_SEARCH
static final java.lang.String DOWN_LINE_OR_SEARCH
- See Also:
- Constant Field Values
-
EDIT_AND_EXECUTE_COMMAND
static final java.lang.String EDIT_AND_EXECUTE_COMMAND
- See Also:
- Constant Field Values
-
EMACS_BACKWARD_WORD
static final java.lang.String EMACS_BACKWARD_WORD
- See Also:
- Constant Field Values
-
EMACS_EDITING_MODE
static final java.lang.String EMACS_EDITING_MODE
- See Also:
- Constant Field Values
-
EMACS_FORWARD_WORD
static final java.lang.String EMACS_FORWARD_WORD
- See Also:
- Constant Field Values
-
END_OF_BUFFER_OR_HISTORY
static final java.lang.String END_OF_BUFFER_OR_HISTORY
- See Also:
- Constant Field Values
-
END_OF_HISTORY
static final java.lang.String END_OF_HISTORY
- See Also:
- Constant Field Values
-
END_OF_LINE
static final java.lang.String END_OF_LINE
- See Also:
- Constant Field Values
-
END_OF_LINE_HIST
static final java.lang.String END_OF_LINE_HIST
- See Also:
- Constant Field Values
-
EXCHANGE_POINT_AND_MARK
static final java.lang.String EXCHANGE_POINT_AND_MARK
- See Also:
- Constant Field Values
-
EXECUTE_NAMED_CMD
static final java.lang.String EXECUTE_NAMED_CMD
- See Also:
- Constant Field Values
-
EXPAND_HISTORY
static final java.lang.String EXPAND_HISTORY
- See Also:
- Constant Field Values
-
EXPAND_OR_COMPLETE
static final java.lang.String EXPAND_OR_COMPLETE
- See Also:
- Constant Field Values
-
EXPAND_OR_COMPLETE_PREFIX
static final java.lang.String EXPAND_OR_COMPLETE_PREFIX
- See Also:
- Constant Field Values
-
EXPAND_WORD
static final java.lang.String EXPAND_WORD
- See Also:
- Constant Field Values
-
FRESH_LINE
static final java.lang.String FRESH_LINE
- See Also:
- Constant Field Values
-
FORWARD_CHAR
static final java.lang.String FORWARD_CHAR
- See Also:
- Constant Field Values
-
FORWARD_WORD
static final java.lang.String FORWARD_WORD
- See Also:
- Constant Field Values
-
HISTORY_BEGINNING_SEARCH_BACKWARD
static final java.lang.String HISTORY_BEGINNING_SEARCH_BACKWARD
- See Also:
- Constant Field Values
-
HISTORY_BEGINNING_SEARCH_FORWARD
static final java.lang.String HISTORY_BEGINNING_SEARCH_FORWARD
- See Also:
- Constant Field Values
-
HISTORY_INCREMENTAL_PATTERN_SEARCH_BACKWARD
static final java.lang.String HISTORY_INCREMENTAL_PATTERN_SEARCH_BACKWARD
- See Also:
- Constant Field Values
-
HISTORY_INCREMENTAL_PATTERN_SEARCH_FORWARD
static final java.lang.String HISTORY_INCREMENTAL_PATTERN_SEARCH_FORWARD
- See Also:
- Constant Field Values
-
HISTORY_INCREMENTAL_SEARCH_BACKWARD
static final java.lang.String HISTORY_INCREMENTAL_SEARCH_BACKWARD
- See Also:
- Constant Field Values
-
HISTORY_INCREMENTAL_SEARCH_FORWARD
static final java.lang.String HISTORY_INCREMENTAL_SEARCH_FORWARD
- See Also:
- Constant Field Values
-
HISTORY_SEARCH_BACKWARD
static final java.lang.String HISTORY_SEARCH_BACKWARD
- See Also:
- Constant Field Values
-
HISTORY_SEARCH_FORWARD
static final java.lang.String HISTORY_SEARCH_FORWARD
- See Also:
- Constant Field Values
-
INSERT_CLOSE_CURLY
static final java.lang.String INSERT_CLOSE_CURLY
- See Also:
- Constant Field Values
-
INSERT_CLOSE_PAREN
static final java.lang.String INSERT_CLOSE_PAREN
- See Also:
- Constant Field Values
-
INSERT_CLOSE_SQUARE
static final java.lang.String INSERT_CLOSE_SQUARE
- See Also:
- Constant Field Values
-
INFER_NEXT_HISTORY
static final java.lang.String INFER_NEXT_HISTORY
- See Also:
- Constant Field Values
-
INSERT_COMMENT
static final java.lang.String INSERT_COMMENT
- See Also:
- Constant Field Values
-
INSERT_LAST_WORD
static final java.lang.String INSERT_LAST_WORD
- See Also:
- Constant Field Values
-
KILL_BUFFER
static final java.lang.String KILL_BUFFER
- See Also:
- Constant Field Values
-
KILL_LINE
static final java.lang.String KILL_LINE
- See Also:
- Constant Field Values
-
KILL_REGION
static final java.lang.String KILL_REGION
- See Also:
- Constant Field Values
-
KILL_WHOLE_LINE
static final java.lang.String KILL_WHOLE_LINE
- See Also:
- Constant Field Values
-
KILL_WORD
static final java.lang.String KILL_WORD
- See Also:
- Constant Field Values
-
LIST_CHOICES
static final java.lang.String LIST_CHOICES
- See Also:
- Constant Field Values
-
LIST_EXPAND
static final java.lang.String LIST_EXPAND
- See Also:
- Constant Field Values
-
MAGIC_SPACE
static final java.lang.String MAGIC_SPACE
- See Also:
- Constant Field Values
-
MENU_EXPAND_OR_COMPLETE
static final java.lang.String MENU_EXPAND_OR_COMPLETE
- See Also:
- Constant Field Values
-
MENU_COMPLETE
static final java.lang.String MENU_COMPLETE
- See Also:
- Constant Field Values
-
MENU_SELECT
static final java.lang.String MENU_SELECT
- See Also:
- Constant Field Values
-
NEG_ARGUMENT
static final java.lang.String NEG_ARGUMENT
- See Also:
- Constant Field Values
-
OVERWRITE_MODE
static final java.lang.String OVERWRITE_MODE
- See Also:
- Constant Field Values
-
PUT_REPLACE_SELECTION
static final java.lang.String PUT_REPLACE_SELECTION
- See Also:
- Constant Field Values
-
QUOTED_INSERT
static final java.lang.String QUOTED_INSERT
- See Also:
- Constant Field Values
-
READ_COMMAND
static final java.lang.String READ_COMMAND
- See Also:
- Constant Field Values
-
RECURSIVE_EDIT
static final java.lang.String RECURSIVE_EDIT
- See Also:
- Constant Field Values
-
REDISPLAY
static final java.lang.String REDISPLAY
- See Also:
- Constant Field Values
-
REDRAW_LINE
static final java.lang.String REDRAW_LINE
- See Also:
- Constant Field Values
-
REDO
static final java.lang.String REDO
- See Also:
- Constant Field Values
-
REVERSE_MENU_COMPLETE
static final java.lang.String REVERSE_MENU_COMPLETE
- See Also:
- Constant Field Values
-
SELF_INSERT
static final java.lang.String SELF_INSERT
- See Also:
- Constant Field Values
-
SELF_INSERT_UNMETA
static final java.lang.String SELF_INSERT_UNMETA
- See Also:
- Constant Field Values
-
SEND_BREAK
static final java.lang.String SEND_BREAK
- See Also:
- Constant Field Values
-
SET_LOCAL_HISTORY
static final java.lang.String SET_LOCAL_HISTORY
- See Also:
- Constant Field Values
-
SET_MARK_COMMAND
static final java.lang.String SET_MARK_COMMAND
- See Also:
- Constant Field Values
-
SPELL_WORD
static final java.lang.String SPELL_WORD
- See Also:
- Constant Field Values
-
SPLIT_UNDO
static final java.lang.String SPLIT_UNDO
- See Also:
- Constant Field Values
-
TRANSPOSE_CHARS
static final java.lang.String TRANSPOSE_CHARS
- See Also:
- Constant Field Values
-
TRANSPOSE_WORDS
static final java.lang.String TRANSPOSE_WORDS
- See Also:
- Constant Field Values
-
UNDEFINED_KEY
static final java.lang.String UNDEFINED_KEY
- See Also:
- Constant Field Values
-
UNDO
static final java.lang.String UNDO
- See Also:
- Constant Field Values
-
UNIVERSAL_ARGUMENT
static final java.lang.String UNIVERSAL_ARGUMENT
- See Also:
- Constant Field Values
-
UP_CASE_WORD
static final java.lang.String UP_CASE_WORD
- See Also:
- Constant Field Values
-
UP_HISTORY
static final java.lang.String UP_HISTORY
- See Also:
- Constant Field Values
-
UP_LINE
static final java.lang.String UP_LINE
- See Also:
- Constant Field Values
-
UP_LINE_OR_HISTORY
static final java.lang.String UP_LINE_OR_HISTORY
- See Also:
- Constant Field Values
-
UP_LINE_OR_SEARCH
static final java.lang.String UP_LINE_OR_SEARCH
- See Also:
- Constant Field Values
-
VI_ADD_EOL
static final java.lang.String VI_ADD_EOL
- See Also:
- Constant Field Values
-
VI_ADD_NEXT
static final java.lang.String VI_ADD_NEXT
- See Also:
- Constant Field Values
-
VI_BACKWARD_BLANK_WORD
static final java.lang.String VI_BACKWARD_BLANK_WORD
- See Also:
- Constant Field Values
-
VI_BACKWARD_BLANK_WORD_END
static final java.lang.String VI_BACKWARD_BLANK_WORD_END
- See Also:
- Constant Field Values
-
VI_BACKWARD_CHAR
static final java.lang.String VI_BACKWARD_CHAR
- See Also:
- Constant Field Values
-
VI_BACKWARD_DELETE_CHAR
static final java.lang.String VI_BACKWARD_DELETE_CHAR
- See Also:
- Constant Field Values
-
VI_BACKWARD_KILL_WORD
static final java.lang.String VI_BACKWARD_KILL_WORD
- See Also:
- Constant Field Values
-
VI_BACKWARD_WORD
static final java.lang.String VI_BACKWARD_WORD
- See Also:
- Constant Field Values
-
VI_BACKWARD_WORD_END
static final java.lang.String VI_BACKWARD_WORD_END
- See Also:
- Constant Field Values
-
VI_BEGINNING_OF_LINE
static final java.lang.String VI_BEGINNING_OF_LINE
- See Also:
- Constant Field Values
-
VI_CHANGE
static final java.lang.String VI_CHANGE
- See Also:
- Constant Field Values
-
VI_CHANGE_EOL
static final java.lang.String VI_CHANGE_EOL
- See Also:
- Constant Field Values
-
VI_CHANGE_WHOLE_LINE
static final java.lang.String VI_CHANGE_WHOLE_LINE
- See Also:
- Constant Field Values
-
VI_CMD_MODE
static final java.lang.String VI_CMD_MODE
- See Also:
- Constant Field Values
-
VI_DELETE
static final java.lang.String VI_DELETE
- See Also:
- Constant Field Values
-
VI_DELETE_CHAR
static final java.lang.String VI_DELETE_CHAR
- See Also:
- Constant Field Values
-
VI_DIGIT_OR_BEGINNING_OF_LINE
static final java.lang.String VI_DIGIT_OR_BEGINNING_OF_LINE
- See Also:
- Constant Field Values
-
VI_DOWN_LINE_OR_HISTORY
static final java.lang.String VI_DOWN_LINE_OR_HISTORY
- See Also:
- Constant Field Values
-
VI_END_OF_LINE
static final java.lang.String VI_END_OF_LINE
- See Also:
- Constant Field Values
-
VI_FETCH_HISTORY
static final java.lang.String VI_FETCH_HISTORY
- See Also:
- Constant Field Values
-
VI_FIND_NEXT_CHAR
static final java.lang.String VI_FIND_NEXT_CHAR
- See Also:
- Constant Field Values
-
VI_FIND_NEXT_CHAR_SKIP
static final java.lang.String VI_FIND_NEXT_CHAR_SKIP
- See Also:
- Constant Field Values
-
VI_FIND_PREV_CHAR
static final java.lang.String VI_FIND_PREV_CHAR
- See Also:
- Constant Field Values
-
VI_FIND_PREV_CHAR_SKIP
static final java.lang.String VI_FIND_PREV_CHAR_SKIP
- See Also:
- Constant Field Values
-
VI_FIRST_NON_BLANK
static final java.lang.String VI_FIRST_NON_BLANK
- See Also:
- Constant Field Values
-
VI_FORWARD_BLANK_WORD
static final java.lang.String VI_FORWARD_BLANK_WORD
- See Also:
- Constant Field Values
-
VI_FORWARD_BLANK_WORD_END
static final java.lang.String VI_FORWARD_BLANK_WORD_END
- See Also:
- Constant Field Values
-
VI_FORWARD_CHAR
static final java.lang.String VI_FORWARD_CHAR
- See Also:
- Constant Field Values
-
VI_FORWARD_WORD
static final java.lang.String VI_FORWARD_WORD
- See Also:
- Constant Field Values
-
VI_FORWARD_WORD_END
static final java.lang.String VI_FORWARD_WORD_END
- See Also:
- Constant Field Values
-
VI_GOTO_COLUMN
static final java.lang.String VI_GOTO_COLUMN
- See Also:
- Constant Field Values
-
VI_HISTORY_SEARCH_BACKWARD
static final java.lang.String VI_HISTORY_SEARCH_BACKWARD
- See Also:
- Constant Field Values
-
VI_HISTORY_SEARCH_FORWARD
static final java.lang.String VI_HISTORY_SEARCH_FORWARD
- See Also:
- Constant Field Values
-
VI_INSERT
static final java.lang.String VI_INSERT
- See Also:
- Constant Field Values
-
VI_INSERT_BOL
static final java.lang.String VI_INSERT_BOL
- See Also:
- Constant Field Values
-
VI_INSERT_COMMENT
static final java.lang.String VI_INSERT_COMMENT
- See Also:
- Constant Field Values
-
VI_JOIN
static final java.lang.String VI_JOIN
- See Also:
- Constant Field Values
-
VI_KILL_EOL
static final java.lang.String VI_KILL_EOL
- See Also:
- Constant Field Values
-
VI_KILL_LINE
static final java.lang.String VI_KILL_LINE
- See Also:
- Constant Field Values
-
VI_MATCH_BRACKET
static final java.lang.String VI_MATCH_BRACKET
- See Also:
- Constant Field Values
-
VI_OPEN_LINE_ABOVE
static final java.lang.String VI_OPEN_LINE_ABOVE
- See Also:
- Constant Field Values
-
VI_OPEN_LINE_BELOW
static final java.lang.String VI_OPEN_LINE_BELOW
- See Also:
- Constant Field Values
-
VI_OPER_SWAP_CASE
static final java.lang.String VI_OPER_SWAP_CASE
- See Also:
- Constant Field Values
-
VI_PUT_AFTER
static final java.lang.String VI_PUT_AFTER
- See Also:
- Constant Field Values
-
VI_PUT_BEFORE
static final java.lang.String VI_PUT_BEFORE
- See Also:
- Constant Field Values
-
VI_QUOTED_INSERT
static final java.lang.String VI_QUOTED_INSERT
- See Also:
- Constant Field Values
-
VI_REPEAT_CHANGE
static final java.lang.String VI_REPEAT_CHANGE
- See Also:
- Constant Field Values
-
VI_REPEAT_FIND
static final java.lang.String VI_REPEAT_FIND
- See Also:
- Constant Field Values
-
VI_REPEAT_SEARCH
static final java.lang.String VI_REPEAT_SEARCH
- See Also:
- Constant Field Values
-
VI_REPLACE
static final java.lang.String VI_REPLACE
- See Also:
- Constant Field Values
-
VI_REPLACE_CHARS
static final java.lang.String VI_REPLACE_CHARS
- See Also:
- Constant Field Values
-
VI_REV_REPEAT_FIND
static final java.lang.String VI_REV_REPEAT_FIND
- See Also:
- Constant Field Values
-
VI_REV_REPEAT_SEARCH
static final java.lang.String VI_REV_REPEAT_SEARCH
- See Also:
- Constant Field Values
-
VI_SET_BUFFER
static final java.lang.String VI_SET_BUFFER
- See Also:
- Constant Field Values
-
VI_SUBSTITUTE
static final java.lang.String VI_SUBSTITUTE
- See Also:
- Constant Field Values
-
VI_SWAP_CASE
static final java.lang.String VI_SWAP_CASE
- See Also:
- Constant Field Values
-
VI_UNDO_CHANGE
static final java.lang.String VI_UNDO_CHANGE
- See Also:
- Constant Field Values
-
VI_UP_LINE_OR_HISTORY
static final java.lang.String VI_UP_LINE_OR_HISTORY
- See Also:
- Constant Field Values
-
VI_YANK
static final java.lang.String VI_YANK
- See Also:
- Constant Field Values
-
VI_YANK_EOL
static final java.lang.String VI_YANK_EOL
- See Also:
- Constant Field Values
-
VI_YANK_WHOLE_LINE
static final java.lang.String VI_YANK_WHOLE_LINE
- See Also:
- Constant Field Values
-
VISUAL_LINE_MODE
static final java.lang.String VISUAL_LINE_MODE
- See Also:
- Constant Field Values
-
VISUAL_MODE
static final java.lang.String VISUAL_MODE
- See Also:
- Constant Field Values
-
WHAT_CURSOR_POSITION
static final java.lang.String WHAT_CURSOR_POSITION
- See Also:
- Constant Field Values
-
YANK
static final java.lang.String YANK
- See Also:
- Constant Field Values
-
YANK_POP
static final java.lang.String YANK_POP
- See Also:
- Constant Field Values
-
MOUSE
static final java.lang.String MOUSE
- See Also:
- Constant Field Values
-
FOCUS_IN
static final java.lang.String FOCUS_IN
- See Also:
- Constant Field Values
-
FOCUS_OUT
static final java.lang.String FOCUS_OUT
- See Also:
- Constant Field Values
-
BEGIN_PASTE
static final java.lang.String BEGIN_PASTE
- See Also:
- Constant Field Values
-
VICMD
static final java.lang.String VICMD
- See Also:
- Constant Field Values
-
VIINS
static final java.lang.String VIINS
- See Also:
- Constant Field Values
-
VIOPP
static final java.lang.String VIOPP
- See Also:
- Constant Field Values
-
VISUAL
static final java.lang.String VISUAL
- See Also:
- Constant Field Values
-
MAIN
static final java.lang.String MAIN
- See Also:
- Constant Field Values
-
EMACS
static final java.lang.String EMACS
- See Also:
- Constant Field Values
-
SAFE
static final java.lang.String SAFE
- See Also:
- Constant Field Values
-
DUMB
static final java.lang.String DUMB
- See Also:
- Constant Field Values
-
MENU
static final java.lang.String MENU
- See Also:
- Constant Field Values
-
BIND_TTY_SPECIAL_CHARS
static final java.lang.String BIND_TTY_SPECIAL_CHARS
- See Also:
- Constant Field Values
-
COMMENT_BEGIN
static final java.lang.String COMMENT_BEGIN
- See Also:
- Constant Field Values
-
BELL_STYLE
static final java.lang.String BELL_STYLE
- See Also:
- Constant Field Values
-
PREFER_VISIBLE_BELL
static final java.lang.String PREFER_VISIBLE_BELL
- See Also:
- Constant Field Values
-
LIST_MAX
static final java.lang.String LIST_MAX
tab completion: if candidates are more than list-max a question will be asked before displaying them- See Also:
- Constant Field Values
-
MENU_LIST_MAX
static final java.lang.String MENU_LIST_MAX
tab completion: if candidates are less than menu-list-max they are displayed in a list below the field to be completed- See Also:
- Constant Field Values
-
DISABLE_HISTORY
static final java.lang.String DISABLE_HISTORY
- See Also:
- Constant Field Values
-
DISABLE_COMPLETION
static final java.lang.String DISABLE_COMPLETION
- See Also:
- Constant Field Values
-
EDITING_MODE
static final java.lang.String EDITING_MODE
- See Also:
- Constant Field Values
-
KEYMAP
static final java.lang.String KEYMAP
- See Also:
- Constant Field Values
-
BLINK_MATCHING_PAREN
static final java.lang.String BLINK_MATCHING_PAREN
- See Also:
- Constant Field Values
-
WORDCHARS
static final java.lang.String WORDCHARS
- See Also:
- Constant Field Values
-
REMOVE_SUFFIX_CHARS
static final java.lang.String REMOVE_SUFFIX_CHARS
- See Also:
- Constant Field Values
-
SEARCH_TERMINATORS
static final java.lang.String SEARCH_TERMINATORS
- See Also:
- Constant Field Values
-
ERRORS
static final java.lang.String ERRORS
Number of matching errors that are accepted by the completion matcher- See Also:
- Constant Field Values
-
OTHERS_GROUP_NAME
static final java.lang.String OTHERS_GROUP_NAME
Property for the "others" group name- See Also:
- Constant Field Values
-
ORIGINAL_GROUP_NAME
static final java.lang.String ORIGINAL_GROUP_NAME
Property for the "original" group name- See Also:
- Constant Field Values
-
COMPLETION_STYLE_GROUP
static final java.lang.String COMPLETION_STYLE_GROUP
Completion style for displaying groups name- See Also:
- Constant Field Values
-
COMPLETION_STYLE_LIST_GROUP
static final java.lang.String COMPLETION_STYLE_LIST_GROUP
- See Also:
- Constant Field Values
-
COMPLETION_STYLE_SELECTION
static final java.lang.String COMPLETION_STYLE_SELECTION
Completion style for displaying the current selected item- See Also:
- Constant Field Values
-
COMPLETION_STYLE_LIST_SELECTION
static final java.lang.String COMPLETION_STYLE_LIST_SELECTION
- See Also:
- Constant Field Values
-
COMPLETION_STYLE_DESCRIPTION
static final java.lang.String COMPLETION_STYLE_DESCRIPTION
Completion style for displaying the candidate description- See Also:
- Constant Field Values
-
COMPLETION_STYLE_LIST_DESCRIPTION
static final java.lang.String COMPLETION_STYLE_LIST_DESCRIPTION
- See Also:
- Constant Field Values
-
COMPLETION_STYLE_STARTING
static final java.lang.String COMPLETION_STYLE_STARTING
Completion style for displaying the matching part of candidates- See Also:
- Constant Field Values
-
COMPLETION_STYLE_LIST_STARTING
static final java.lang.String COMPLETION_STYLE_LIST_STARTING
- See Also:
- Constant Field Values
-
COMPLETION_STYLE_BACKGROUND
static final java.lang.String COMPLETION_STYLE_BACKGROUND
Completion style for displaying the list- See Also:
- Constant Field Values
-
COMPLETION_STYLE_LIST_BACKGROUND
static final java.lang.String COMPLETION_STYLE_LIST_BACKGROUND
- See Also:
- Constant Field Values
-
SECONDARY_PROMPT_PATTERN
static final java.lang.String SECONDARY_PROMPT_PATTERN
Set the template for prompts for secondary (continuation) lines. This is a prompt template as described in the class header.- See Also:
- Constant Field Values
-
LINE_OFFSET
static final java.lang.String LINE_OFFSET
When in multiline edit mode, this variable can be used to offset the line number displayed.- See Also:
- Constant Field Values
-
AMBIGUOUS_BINDING
static final java.lang.String AMBIGUOUS_BINDING
Timeout for ambiguous key sequences. If the key sequence is ambiguous, i.e. there is a matching sequence but the sequence is also a prefix for other bindings, the next key press will be waited for a specified amount of time. If the timeout elapses, the matched sequence will be used.- See Also:
- Constant Field Values
-
HISTORY_IGNORE
static final java.lang.String HISTORY_IGNORE
Colon separated list of patterns that will not be saved in history.- See Also:
- Constant Field Values
-
HISTORY_FILE
static final java.lang.String HISTORY_FILE
File system history path.- See Also:
- Constant Field Values
-
HISTORY_SIZE
static final java.lang.String HISTORY_SIZE
Number of history items to keep in memory.- See Also:
- Constant Field Values
-
HISTORY_FILE_SIZE
static final java.lang.String HISTORY_FILE_SIZE
Number of history items to keep in the history file.- See Also:
- Constant Field Values
-
INDENTATION
static final java.lang.String INDENTATION
New line automatic indentation after opening/closing bracket.- See Also:
- Constant Field Values
-
FEATURES_MAX_BUFFER_SIZE
static final java.lang.String FEATURES_MAX_BUFFER_SIZE
Max buffer size for advanced features. Once the length of the buffer reaches this threshold, no advanced features will be enabled. This includes the undo buffer, syntax highlighting, parsing, etc....- See Also:
- Constant Field Values
-
SUGGESTIONS_MIN_BUFFER_SIZE
static final java.lang.String SUGGESTIONS_MIN_BUFFER_SIZE
Min buffer size for tab auto-suggestions. For shorter buffer sizes auto-suggestions are not resolved.- See Also:
- Constant Field Values
-
MAX_REPEAT_COUNT
static final java.lang.String MAX_REPEAT_COUNT
Max number of times a command can be repeated.- See Also:
- Constant Field Values
-
TAB_WIDTH
static final java.lang.String TAB_WIDTH
Number of spaces to display a tabulation, the default is 4.- See Also:
- Constant Field Values
-
INPUT_RC_FILE_NAME
static final java.lang.String INPUT_RC_FILE_NAME
Name of inputrc to read at line reader creation time.- See Also:
- Constant Field Values
-
SYSTEM_PROPERTY_PREFIX
static final java.lang.String SYSTEM_PROPERTY_PREFIX
Prefix to automatically delegate variables to system properties- See Also:
- Constant Field Values
-
-
Method Detail
-
defaultKeyMaps
java.util.Map<java.lang.String,KeyMap<Binding>> defaultKeyMaps()
Returns the default key maps used by the LineReader.These key maps define the standard key bindings for different editing modes such as Emacs mode, Vi command mode, Vi insert mode, etc.
- Returns:
- a map of key map names to key maps
-
readLine
java.lang.String readLine() throws UserInterruptException, EndOfFileExceptionRead the next line and return the contents of the buffer. Equivalent toreadLine(null, null, null).- Returns:
- the line read
- Throws:
UserInterruptException- if readLine was interrupted (using Ctrl-C for example)EndOfFileException- if an EOF has been found (using Ctrl-D for example)java.io.IOError- in case of other i/o errors
-
readLine
java.lang.String readLine(java.lang.Character mask) throws UserInterruptException, EndOfFileExceptionRead the next line with the specified character mask. If null, then characters will be echoed. If 0, then no characters will be echoed. Equivalent toreadLine(null, mask, null)- Parameters:
mask- The mask character,nullor0.- Returns:
- A line that is read from the terminal, can never be null.
- Throws:
UserInterruptException- if readLine was interrupted (using Ctrl-C for example)EndOfFileException- if an EOF has been found (using Ctrl-D for example)java.io.IOError- in case of other i/o errors
-
readLine
java.lang.String readLine(java.lang.String prompt) throws UserInterruptException, EndOfFileExceptionRead the next line with the specified prompt. If null, then the default prompt will be used. Equivalent toreadLine(prompt, null, null)- Parameters:
prompt- The prompt to issue to the terminal, may be null.- Returns:
- A line that is read from the terminal, can never be null.
- Throws:
UserInterruptException- if readLine was interrupted (using Ctrl-C for example)EndOfFileException- if an EOF has been found (using Ctrl-D for example)java.io.IOError- in case of other i/o errors
-
readLine
java.lang.String readLine(java.lang.String prompt, java.lang.Character mask) throws UserInterruptException, EndOfFileExceptionRead a line from the inInputStream, and return the line (without any trailing newlines). Equivalent toreadLine(prompt, mask, null)- Parameters:
prompt- The prompt to issue to the terminal, may be null.mask- The mask character,nullor0.- Returns:
- A line that is read from the terminal, can never be null.
- Throws:
UserInterruptException- if readLine was interrupted (using Ctrl-C for example)EndOfFileException- if an EOF has been found (using Ctrl-D for example)java.io.IOError- in case of other i/o errors
-
readLine
java.lang.String readLine(java.lang.String prompt, java.lang.Character mask, java.lang.String buffer) throws UserInterruptException, EndOfFileExceptionRead a line from the inInputStream, and return the line (without any trailing newlines). Equivalent toreadLine(prompt, null, mask, buffer)- Parameters:
prompt- The prompt to issue to the terminal, may be null. This is a template, with optional'%'escapes, as described in the class header.mask- The character mask, may be null.buffer- The default value presented to the user to edit, may be null.- Returns:
- A line that is read from the terminal, can never be null.
- Throws:
UserInterruptException- if readLine was interrupted (using Ctrl-C for example)EndOfFileException- if an EOF has been found (using Ctrl-D for example)java.io.IOError- in case of other i/o errors
-
readLine
java.lang.String readLine(java.lang.String prompt, java.lang.String rightPrompt, java.lang.Character mask, java.lang.String buffer) throws UserInterruptException, EndOfFileExceptionRead a line from the inInputStream, and return the line (without any trailing newlines).- Parameters:
prompt- The prompt to issue to the terminal, may be null. This is a template, with optional'%'escapes, as described in the class header.rightPrompt- The right prompt This is a template, with optional'%'escapes, as described in the class header.mask- The character mask, may be null.buffer- The default value presented to the user to edit, may be null.- Returns:
- A line that is read from the terminal, can never be null.
- Throws:
UserInterruptException- if readLine was interrupted (using Ctrl-C for example)EndOfFileException- if an EOF has been found (using Ctrl-D for example)java.io.IOError- in case of other i/o errors
-
readLine
java.lang.String readLine(java.lang.String prompt, java.lang.String rightPrompt, MaskingCallback maskingCallback, java.lang.String buffer) throws UserInterruptException, EndOfFileExceptionRead a line from the inInputStream, and return the line (without any trailing newlines).- Parameters:
prompt- The prompt to issue to the terminal, may be null. This is a template, with optional'%'escapes, as described in the class header.rightPrompt- The right prompt This is a template, with optional'%'escapes, as described in the class header.maskingCallback- TheMaskingCallbackto use when displaying lines and adding them to the lineHistorybuffer- The default value presented to the user to edit, may be null.- Returns:
- A line that is read from the terminal, can never be null.
- Throws:
UserInterruptException- if readLine was interrupted (using Ctrl-C for example)EndOfFileException- if an EOF has been found (using Ctrl-D for example)java.io.IOError- in case of other i/o errors
-
printAbove
void printAbove(java.lang.String str)
Prints a line above the prompt and redraw everything. If the LineReader is not actually reading a line, the string will simply be printed to the terminal.- Parameters:
str- the string to print- See Also:
printAbove(AttributedString)
-
printAbove
void printAbove(AttributedString str)
Prints a string before the prompt and redraw everything. If the LineReader is not actually reading a line, the string will simply be printed to the terminal.- Parameters:
str- the string to print- See Also:
printAbove(String)
-
isReading
boolean isReading()
Check if a thread is currently in areadLine()call.- Returns:
trueif there is an ongoingreadLine()call.
-
variable
LineReader variable(java.lang.String name, java.lang.Object value)
Sets a variable in the LineReader and returns the LineReader for method chaining.Variables control various aspects of the LineReader's behavior. See the various variable constants defined in this interface for available options.
- Parameters:
name- the variable namevalue- the variable value- Returns:
- this LineReader
-
option
LineReader option(LineReader.Option option, boolean value)
Sets an option in the LineReader and returns the LineReader for method chaining.Options control various aspects of the LineReader's behavior. See the
LineReader.Optionenum for available options.- Parameters:
option- the option to setvalue- the option value- Returns:
- this LineReader
-
callWidget
void callWidget(java.lang.String name)
Calls a widget by name.Widgets are functions that perform editing operations. This method allows invoking a widget programmatically rather than through a key binding.
- Parameters:
name- the name of the widget to call
-
getVariables
java.util.Map<java.lang.String,java.lang.Object> getVariables()
Returns a map of all variables set in the LineReader.Variables control various aspects of the LineReader's behavior. See the various variable constants defined in this interface for available options.
- Returns:
- a map of variable names to their values
-
getVariable
java.lang.Object getVariable(java.lang.String name)
Returns the value of a variable.Variables control various aspects of the LineReader's behavior. See the various variable constants defined in this interface for available options.
- Parameters:
name- the variable name- Returns:
- the variable value, or null if the variable is not set
-
setVariable
void setVariable(java.lang.String name, java.lang.Object value)Sets a variable in the LineReader.Variables control various aspects of the LineReader's behavior. See the various variable constants defined in this interface for available options.
- Parameters:
name- the variable namevalue- the variable value
-
isSet
boolean isSet(LineReader.Option option)
Checks if an option is set.Options control various aspects of the LineReader's behavior. See the
LineReader.Optionenum for available options.- Parameters:
option- the option to check- Returns:
- true if the option is set, false otherwise
-
setOpt
void setOpt(LineReader.Option option)
Sets an option to true.Options control various aspects of the LineReader's behavior. See the
LineReader.Optionenum for available options.- Parameters:
option- the option to set
-
unsetOpt
void unsetOpt(LineReader.Option option)
Sets an option to false.Options control various aspects of the LineReader's behavior. See the
LineReader.Optionenum for available options.- Parameters:
option- the option to unset
-
getTerminal
Terminal getTerminal()
Returns the terminal associated with this LineReader.The terminal is used for input/output operations and provides information about the terminal capabilities and size.
- Returns:
- the terminal
-
getWidgets
java.util.Map<java.lang.String,Widget> getWidgets()
Returns a map of all widgets registered with this LineReader.Widgets are functions that perform editing operations and can be bound to key sequences.
- Returns:
- a map of widget names to widgets
-
getBuiltinWidgets
java.util.Map<java.lang.String,Widget> getBuiltinWidgets()
Returns a map of all built-in widgets provided by the LineReader.Built-in widgets implement standard editing operations like cursor movement, text deletion, history navigation, etc.
- Returns:
- a map of built-in widget names to widgets
-
getBuffer
Buffer getBuffer()
Returns the current line buffer.The buffer contains the text that the user is currently editing. It provides methods for manipulating the text and cursor position.
- Returns:
- the current line buffer
-
getAppName
java.lang.String getAppName()
Returns the application name associated with this LineReader.The application name is used for various purposes, such as naming history files and identifying the application in terminal titles.
- Returns:
- the application name
-
runMacro
void runMacro(java.lang.String macro)
Push back a key sequence that will be later consumed by the line reader. This method can be used after reading the cursor position usingTerminal.getCursorPosition(IntConsumer).- Parameters:
macro- the key sequence to push back- See Also:
Terminal.getCursorPosition(IntConsumer),readMouseEvent()
-
readMouseEvent
MouseEvent readMouseEvent()
Read a mouse event when theInfoCmp.Capability.key_mousesequence has just been read on the input stream. Compared toTerminal.readMouseEvent(), this method takes into account keys that have been pushed back usingrunMacro(String).- Returns:
- the mouse event
- See Also:
runMacro(String),Terminal.getCursorPosition(IntConsumer)
-
getHistory
History getHistory()
Returns the history associated with this LineReader.The history stores previously entered command lines and provides methods for navigating, searching, and managing history entries.
- Returns:
- the command history
-
getParser
Parser getParser()
Returns the parser associated with this LineReader.The parser is responsible for breaking command lines into tokens according to the syntax rules of the shell or application.
- Returns:
- the parser
-
getHighlighter
Highlighter getHighlighter()
Returns the highlighter associated with this LineReader.The highlighter is responsible for applying syntax highlighting to the command line as the user types.
- Returns:
- the highlighter
-
getExpander
Expander getExpander()
Returns the expander associated with this LineReader.The expander is responsible for expanding special syntax in the command line, such as history references (e.g., !!, !$) and variables (e.g., $HOME).
- Returns:
- the expander
-
getKeyMaps
java.util.Map<java.lang.String,KeyMap<Binding>> getKeyMaps()
Returns all key maps registered with this LineReader.Key maps define the mappings from key sequences to actions for different editing modes (e.g., Emacs mode, Vi command mode, Vi insert mode).
- Returns:
- a map of key map names to key maps
-
getKeyMap
java.lang.String getKeyMap()
Returns the name of the currently active key map.The active key map determines how key presses are interpreted and which actions they trigger.
- Returns:
- the name of the active key map
-
setKeyMap
boolean setKeyMap(java.lang.String name)
Sets the active key map by name.The active key map determines how key presses are interpreted and which actions they trigger.
- Parameters:
name- the name of the key map to activate- Returns:
- true if the key map was successfully set, false if the key map does not exist
-
getKeys
KeyMap<Binding> getKeys()
Returns the currently active key map.The active key map determines how key presses are interpreted and which actions they trigger.
- Returns:
- the active key map
-
getParsedLine
ParsedLine getParsedLine()
Returns the parsed representation of the current line.The parsed line contains the tokenized form of the current input line, broken down according to the syntax rules of the parser.
- Returns:
- the parsed line, or null if the line has not been parsed yet
-
getSearchTerm
java.lang.String getSearchTerm()
Returns the current search term when in history search mode.This is the string that the user is searching for in the command history.
- Returns:
- the current search term, or null if not in search mode
-
getRegionActive
LineReader.RegionType getRegionActive()
Returns the type of the currently active region selection.The region is a selected portion of text in the buffer, similar to a selection in a text editor.
- Returns:
- the type of the active region, or
LineReader.RegionType.NONEif no region is active
-
getRegionMark
int getRegionMark()
Returns the mark position of the currently active region.The mark is one endpoint of the selected region, with the cursor being the other endpoint.
- Returns:
- the position of the mark, or -1 if no region is active
-
addCommandsInBuffer
void addCommandsInBuffer(java.util.Collection<java.lang.String> commands)
Adds a collection of commands to the input buffer for execution.These commands will be executed one by one when the user accepts the current line. This is useful for implementing features like command scripts or macros.
- Parameters:
commands- the commands to add to the buffer
-
editAndAddInBuffer
default void editAndAddInBuffer(java.io.File file) throws java.lang.ExceptionOpens a file in an external editor and adds its contents to the input buffer.This method allows the user to edit a file in their preferred text editor and then have its contents added to the input buffer for execution.
- Parameters:
file- the file to edit, or null to create a temporary file- Throws:
java.lang.Exception- if an error occurs while editing the file- See Also:
editAndAddInBuffer(Path)
-
editAndAddInBuffer
void editAndAddInBuffer(java.nio.file.Path file) throws java.lang.ExceptionOpens a file in an external editor and adds its contents to the input buffer.This method allows the user to edit a file in their preferred text editor and then have its contents added to the input buffer for execution.
- Parameters:
file- the file to edit, or null to create a temporary file- Throws:
java.lang.Exception- if an error occurs while editing the file
-
getLastBinding
java.lang.String getLastBinding()
Returns the last key binding that was processed.This is the string representation of the last key sequence that triggered an action.
- Returns:
- the last key binding, or null if no binding has been processed
-
getTailTip
java.lang.String getTailTip()
Returns the current tail tip text.The tail tip is a hint or suggestion displayed at the end of the current line, typically showing command syntax or parameter information.
- Returns:
- the current tail tip text, or null if no tail tip is set
-
setTailTip
void setTailTip(java.lang.String tailTip)
Sets the tail tip text.The tail tip is a hint or suggestion displayed at the end of the current line, typically showing command syntax or parameter information.
- Parameters:
tailTip- the tail tip text to display, or null to clear the tail tip
-
setAutosuggestion
void setAutosuggestion(LineReader.SuggestionType type)
Sets the type of auto-suggestion to use.Auto-suggestions provide inline completion suggestions as the user types, based on history, completers, or other sources.
- Parameters:
type- the type of auto-suggestion to use
-
getAutosuggestion
LineReader.SuggestionType getAutosuggestion()
Returns the current auto-suggestion type.Auto-suggestions provide inline completion suggestions as the user types, based on history, completers, or other sources.
- Returns:
- the current auto-suggestion type
-
zeroOut
void zeroOut()
Clears any internal buffers and sensitive data.This method is used to ensure that sensitive information, such as passwords or other confidential data, is removed from memory when it's no longer needed. It should be called when the LineReader is no longer in use or before reading sensitive information.
-
-