de.schwarzrot.system
Class CommandReader
java.lang.Object
de.schwarzrot.system.CommandReader
public class CommandReader
- extends Object
class to execute an external (command line) application, with support for
processing output from that application. It will add an executor for files,
that are not really executables, like scripts of jar-files.
- Author:
- Reinhard Mantey
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CommandReader
public CommandReader(List<String> cmdArgs)
CommandReader
public CommandReader(List<String> cmdArgs,
String userName)
CommandReader
public CommandReader(String command)
CommandReader
public CommandReader(String command,
String userName)
isRedirectError
public final boolean isRedirectError()
- Returns:
- the redirectError
setCharset
public void setCharset(String charSet)
setDirectory
public void setDirectory(File dir)
setRedirectError
public final void setRedirectError(boolean redirectError)
- Parameters:
redirectError
- the redirectError to set
start
public Process start()
throws IOException
- Throws:
IOException
startErrorReader
public BufferedReader startErrorReader(Process proc)
startReader
public BufferedReader startReader(Process proc)
dump
protected void dump()
initCommand
protected void initCommand(List<String> cmdParts)
initCommand
protected void initCommand(String rawCmd)
isExecutable
public static boolean isExecutable(File file2Execute)
Submit
a bug or request a feature
SRJRCFrames is published according to the
GNU General Public License
Copyright 2005-2012
Reinhard Mantey - some rights reserved.