Package org.jline.builtins
Class Less
- java.lang.Object
-
- org.jline.builtins.Less
-
public class Less extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
Less.Operation
-
Field Summary
Fields Modifier and Type Field Description protected org.jline.keymap.BindingReader
bindingReader
protected java.lang.StringBuilder
buffer
boolean
chopLongLines
protected java.nio.file.Path
currentDir
protected org.jline.utils.Display
display
protected java.lang.String
displayPattern
protected java.lang.String
errorMessage
protected int
firstColumnToDisplay
protected int
firstLineInMemory
protected int
firstLineToDisplay
protected int
halfWindow
boolean
ignoreCaseAlways
boolean
ignoreCaseCond
protected org.jline.keymap.KeyMap<Less.Operation>
keys
protected java.util.List<org.jline.utils.AttributedString>
lines
protected java.lang.String
message
protected int
nbEof
boolean
noInit
boolean
noKeypad
protected int
offsetInLine
protected java.util.Map<java.lang.String,Less.Operation>
options
protected java.lang.String
pattern
protected Nano.PatternHistory
patternHistory
boolean
printLineNumbers
boolean
quiet
boolean
quitAtFirstEof
boolean
quitAtSecondEof
boolean
quitIfOneScreen
protected java.io.BufferedReader
reader
protected org.jline.terminal.Size
size
protected int
sourceIdx
protected java.util.List<Source>
sources
protected java.lang.String
syntaxName
protected java.util.List<java.lang.Integer>
tabs
protected org.jline.terminal.Terminal
terminal
boolean
veryQuiet
protected int
window
-
Constructor Summary
Constructors Constructor Description Less(org.jline.terminal.Terminal terminal, java.nio.file.Path currentDir)
Less(org.jline.terminal.Terminal terminal, java.nio.file.Path currentDir, Options opts)
Less(org.jline.terminal.Terminal terminal, java.nio.file.Path currentDir, Options opts, ConfigurationPath configPath)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
checkInterrupted()
This is for long running commands to be interrupted by ctrl-cvoid
handle(org.jline.terminal.Terminal.Signal signal)
protected void
openSource()
void
run(java.util.List<Source> sources)
void
run(Source... sources)
Less
tabs(java.util.List<java.lang.Integer> tabs)
static java.lang.String[]
usage()
-
-
-
Field Detail
-
quitAtSecondEof
public boolean quitAtSecondEof
-
quitAtFirstEof
public boolean quitAtFirstEof
-
quitIfOneScreen
public boolean quitIfOneScreen
-
printLineNumbers
public boolean printLineNumbers
-
quiet
public boolean quiet
-
veryQuiet
public boolean veryQuiet
-
chopLongLines
public boolean chopLongLines
-
ignoreCaseCond
public boolean ignoreCaseCond
-
ignoreCaseAlways
public boolean ignoreCaseAlways
-
noKeypad
public boolean noKeypad
-
noInit
public boolean noInit
-
tabs
protected java.util.List<java.lang.Integer> tabs
-
syntaxName
protected java.lang.String syntaxName
-
terminal
protected final org.jline.terminal.Terminal terminal
-
display
protected final org.jline.utils.Display display
-
bindingReader
protected final org.jline.keymap.BindingReader bindingReader
-
currentDir
protected final java.nio.file.Path currentDir
-
sources
protected java.util.List<Source> sources
-
sourceIdx
protected int sourceIdx
-
reader
protected java.io.BufferedReader reader
-
keys
protected org.jline.keymap.KeyMap<Less.Operation> keys
-
firstLineInMemory
protected int firstLineInMemory
-
lines
protected java.util.List<org.jline.utils.AttributedString> lines
-
firstLineToDisplay
protected int firstLineToDisplay
-
firstColumnToDisplay
protected int firstColumnToDisplay
-
offsetInLine
protected int offsetInLine
-
message
protected java.lang.String message
-
errorMessage
protected java.lang.String errorMessage
-
buffer
protected final java.lang.StringBuilder buffer
-
options
protected final java.util.Map<java.lang.String,Less.Operation> options
-
window
protected int window
-
halfWindow
protected int halfWindow
-
nbEof
protected int nbEof
-
patternHistory
protected Nano.PatternHistory patternHistory
-
pattern
protected java.lang.String pattern
-
displayPattern
protected java.lang.String displayPattern
-
size
protected final org.jline.terminal.Size size
-
-
Constructor Detail
-
Less
public Less(org.jline.terminal.Terminal terminal, java.nio.file.Path currentDir)
-
Less
public Less(org.jline.terminal.Terminal terminal, java.nio.file.Path currentDir, Options opts)
-
Less
public Less(org.jline.terminal.Terminal terminal, java.nio.file.Path currentDir, Options opts, ConfigurationPath configPath)
-
-
Method Detail
-
usage
public static java.lang.String[] usage()
-
tabs
public Less tabs(java.util.List<java.lang.Integer> tabs)
-
handle
public void handle(org.jline.terminal.Terminal.Signal signal)
-
run
public void run(Source... sources) throws java.io.IOException, java.lang.InterruptedException
- Throws:
java.io.IOException
java.lang.InterruptedException
-
run
public void run(java.util.List<Source> sources) throws java.io.IOException, java.lang.InterruptedException
- Throws:
java.io.IOException
java.lang.InterruptedException
-
openSource
protected void openSource() throws java.io.IOException
- Throws:
java.io.IOException
-
checkInterrupted
public static void checkInterrupted() throws java.lang.InterruptedException
This is for long running commands to be interrupted by ctrl-c- Throws:
java.lang.InterruptedException
- if the thread has been interruped
-
-