Package sqlline
Class SqlLineOpts
- java.lang.Object
-
- sqlline.SqlLineOpts
-
- All Implemented Interfaces:
org.jline.reader.Completer
public class SqlLineOpts extends Object implements org.jline.reader.Completer
Session options.
-
-
Field Summary
Fields Modifier and Type Field Description static String
PROPERTY_NAME_EXIT
static String
PROPERTY_PREFIX
-
Constructor Summary
Constructors Constructor Description SqlLineOpts(SqlLine sqlLine)
SqlLineOpts(SqlLine sqlLine, Properties props)
-
Method Summary
-
-
-
Field Detail
-
PROPERTY_PREFIX
public static final String PROPERTY_PREFIX
- See Also:
- Constant Field Values
-
PROPERTY_NAME_EXIT
public static final String PROPERTY_NAME_EXIT
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
SqlLineOpts
public SqlLineOpts(SqlLine sqlLine)
-
SqlLineOpts
public SqlLineOpts(SqlLine sqlLine, Properties props)
-
-
Method Detail
-
optionCompleters
public List<org.jline.reader.Completer> optionCompleters()
-
saveDir
public static File saveDir()
The save directory if HOME/.sqlline/ on UNIX, and HOME/sqlline/ on Windows.- Returns:
- save directory
-
complete
public void complete(org.jline.reader.LineReader lineReader, org.jline.reader.ParsedLine parsedLine, List<org.jline.reader.Candidate> list)
- Specified by:
complete
in interfaceorg.jline.reader.Completer
-
save
public void save() throws IOException
- Throws:
IOException
-
save
public void save(OutputStream out)
-
toProperties
public Properties toProperties()
-
toProperties
public Properties toProperties(boolean toSave)
-
load
public void load() throws IOException
- Throws:
IOException
-
load
public void load(InputStream fin) throws IOException
- Throws:
IOException
-
loadProperties
public void loadProperties(Properties props)
-
hasProperty
public boolean hasProperty(String name)
-
get
public String get(SqlLineProperty key)
-
getChar
public char getChar(SqlLineProperty key)
-
getInt
public int getInt(SqlLineProperty key)
-
getBoolean
public boolean getBoolean(SqlLineProperty key)
-
set
public void set(SqlLineProperty key, Object value)
-
getFastConnect
public boolean getFastConnect()
-
getAutoCommit
public boolean getAutoCommit()
-
getVerbose
public boolean getVerbose()
-
getShowElapsedTime
public boolean getShowElapsedTime()
-
getShowWarnings
public boolean getShowWarnings()
-
getShowNestedErrs
public boolean getShowNestedErrs()
-
getNumberFormat
public String getNumberFormat()
-
getEscapeOutput
public boolean getEscapeOutput()
-
setNumberFormat
public void setNumberFormat(String numberFormat)
-
getDateFormat
public String getDateFormat()
-
setDateFormat
public void setDateFormat(String dateFormat)
-
getTimeFormat
public String getTimeFormat()
-
setTimeFormat
public void setTimeFormat(String timeFormat)
-
getTimestampFormat
public String getTimestampFormat()
-
setTimestampFormat
public void setTimestampFormat(String timestampFormat)
-
getNullValue
public String getNullValue()
-
getRowLimit
public int getRowLimit()
-
getTimeout
public int getTimeout()
-
getIsolation
public String getIsolation()
-
setIsolation
public void setIsolation(String isolation)
-
getHistoryFile
public String getHistoryFile()
-
setHistoryFile
public void setHistoryFile(String historyFile)
-
setColorScheme
public void setColorScheme(String colorScheme)
-
getColorScheme
public String getColorScheme()
-
getColor
public boolean getColor()
-
getCsvDelimiter
public String getCsvDelimiter()
-
getCsvQuoteCharacter
public char getCsvQuoteCharacter()
-
setMaxHistoryRows
public void setMaxHistoryRows(String maxHistoryRows)
-
setMaxHistoryFileRows
public void setMaxHistoryFileRows(String maxHistoryFileRows)
-
setCsvQuoteCharacter
public void setCsvQuoteCharacter(String csvQuoteCharacter)
-
getShowHeader
public boolean getShowHeader()
-
getHeaderInterval
public int getHeaderInterval()
-
getForce
public boolean getForce()
-
getIncremental
public boolean getIncremental()
-
getSilent
public boolean getSilent()
-
getAutosave
@Deprecated public boolean getAutosave()
Deprecated.UsegetAutoSave()
- Returns:
- true if auto save is on, false otherwise
-
getAutoSave
public boolean getAutoSave()
-
getOutputFormat
public String getOutputFormat()
-
getPrompt
public String getPrompt()
-
getRightPrompt
public String getRightPrompt()
-
getTrimScripts
public boolean getTrimScripts()
-
getMaxHeight
public int getMaxHeight()
-
getMaxWidth
public int getMaxWidth()
-
getMaxColumnWidth
public int getMaxColumnWidth()
-
getUseLineContinuation
public boolean getUseLineContinuation()
-
getMode
public String getMode()
-
setMode
public void setMode(String mode)
-
getStrictJdbc
public boolean getStrictJdbc()
-
getPropertiesFile
public File getPropertiesFile()
-
setRun
public void setRun(String runFile)
-
getRun
public String getRun()
-
-