|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.enough.polish.emulator.process.ProcessCondition
public class ProcessCondition
Blocks until an started process is finished. While
the process is running, filter() matches
each line printed by the process with the regex
Copyright Enough Software 2008-2009
| Constructor Summary | |
|---|---|
ProcessCondition(String[] arguments,
String regex)
Constructs a new Condition instance. |
|
ProcessCondition(String[] arguments,
String[] regexes)
Constructs a new Condition instance. |
|
| Method Summary | |
|---|---|
void |
filter(String message,
PrintStream output)
Filters the given message. |
boolean |
isMet()
Calls the process, waits until it is finished and returns result. |
protected boolean |
matches(String message)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ProcessCondition(String[] arguments,
String regex)
arguments - the arguments to start the processregex - the regex to match
public ProcessCondition(String[] arguments,
String[] regexes)
arguments - the arguments to start the processregexes - the regexes to match| Method Detail |
|---|
public void filter(String message,
PrintStream output)
OutputFilter
filter in interface OutputFiltermessage - the messageoutput - the output stream to which the message can be written.protected boolean matches(String message)
public boolean isMet()
throws IOException
result.
IOException - if an process error occurs
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||