Package org.h2.dev.fs

# Class FileShell

java.lang.Object
org.h2.util.Tool
org.h2.dev.fs.FileShell

public class FileShell extends Tool
A shell tool that allows to list and manipulate files.

## Field Summary

### Fields inherited from class org.h2.util.Tool

`out`

## Constructor Summary

Constructors
Constructor
Description
`FileShell()`

## Method Summary

Modifier and Type
Method
Description
`static void`
`main(String... args)`
Options are case sensitive.
`void`
`runTool(String... args)`
Run the shell tool with the given command line settings.
`void`
`setErr(PrintStream err)`
Sets the standard error stream.
`void`
`setIn(InputStream in)`
Redirects the standard input.
`void`
`setInReader(BufferedReader reader)`
Redirects the standard input.

### Methods inherited from class org.h2.util.Tool

`getMainClassName, isOption, printNoDatabaseFilesFound, setOut, showUsage, showUsageAndThrowUnsupportedOption, throwUnsupportedOption`

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

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

## Constructor Details

### FileShell

public FileShell()

## Method Details

### main

public static void main(String... args) throws SQLException
Options are case sensitive.

Supported options
[-help] or [-?] | Print the list of options
[-verbose] | Print stack traces
[-run ...] | Execute the given commands and exit

Multiple commands may be executed if separated by ;

Parameters:
  `args` - the command line arguments
Throws:
  `SQLException` - on failure

### setErr

public void setErr(PrintStream err)
Sets the standard error stream.

Parameters:
  `err` - the new standard error stream

### setIn

public void setIn(InputStream in)
Redirects the standard input. By default, System.in is used.

Parameters:
  `in` - the input stream to use

### setInReader

public void setInReader(BufferedReader reader)
Redirects the standard input. By default, System.in is used.

Parameters:
  `reader` - the input stream reader to use

### runTool

public void runTool(String... args) throws SQLException
Run the shell tool with the given command line settings.

Specified by:
  `runTool` in class `Tool`
Parameters:
  `args` - the command line settings
Throws:
  `SQLException` - on failure