|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.compomics.util.gui.waiting.waitinghandlers.WaitingHandlerCLIImpl
public class WaitingHandlerCLIImpl
This class is an implementation of the WaitingHandler interface to be used when operating through the Command Line Interface.
Field Summary | |
---|---|
protected String |
iReport
|
Constructor Summary | |
---|---|
WaitingHandlerCLIImpl()
|
Method Summary | |
---|---|
void |
appendReport(String report,
boolean includeDate,
boolean addNewLine)
Append text to the report. |
void |
appendReportEndLine()
Append a new line to the report. |
void |
appendReportNewLineNoDate()
Append two tabs to the report. |
void |
displayHtmlMessage(JEditorPane messagePane,
String title,
int messageType)
Display a given html containing message to the user separatly from the main output. |
void |
displayMessage(String message,
String title,
int messageType)
Display a given message to the user separatly from the main output. |
JProgressBar |
getPrimaryProgressBar()
Returns the primary progress bar for updates from external processes. |
JProgressBar |
getSecondaryProgressBar()
Returns the secondary progress bar for updates from external processes. |
void |
increaseProgressValue()
Increase the progress bar value by one "counter". |
void |
increaseProgressValue(int amount)
Increase the progress bar value by the given amount. |
void |
increaseSecondaryProgressValue()
Increase the secondary progress bar value by one "counter". |
void |
increaseSecondaryProgressValue(int amount)
Increase the secondary progress bar value by the given amount. |
boolean |
isRunCanceled()
Returns true if the run is canceled. |
void |
resetSecondaryProgressBar()
Reset the secondary progress bar value to 0. |
void |
setMaxProgressValue(int maxProgressValue)
Set the maximum value of the progress bar. |
void |
setMaxSecondaryProgressValue(int maxProgressValue)
Set the maximum value of the secondary progress bar. |
void |
setRunCanceled()
Set the analysis as canceled. |
void |
setRunFinished()
Set the analysis as finished. |
void |
setSecondaryProgressDialogIndeterminate(boolean intermediate)
Sets the secondary progress bar to intermediate or not. |
void |
setSecondaryProgressValue(int value)
Sets the secondary progress bar to the given value. |
void |
setWaitingText(String text)
Sets the text describing what is currently waited for. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected String iReport
Constructor Detail |
---|
public WaitingHandlerCLIImpl()
Method Detail |
---|
public void setMaxProgressValue(int maxProgressValue)
setMaxProgressValue
in interface WaitingHandler
maxProgressValue
- the max valuepublic void increaseProgressValue()
increaseProgressValue
in interface WaitingHandler
public void increaseProgressValue(int amount)
increaseProgressValue
in interface WaitingHandler
amount
- the amount to increase the value bypublic void setMaxSecondaryProgressValue(int maxProgressValue)
setMaxSecondaryProgressValue
in interface WaitingHandler
maxProgressValue
- the max valuepublic void resetSecondaryProgressBar()
resetSecondaryProgressBar
in interface WaitingHandler
public void increaseSecondaryProgressValue()
increaseSecondaryProgressValue
in interface WaitingHandler
public void setSecondaryProgressValue(int value)
setSecondaryProgressValue
in interface WaitingHandler
value
- the progress valuepublic void increaseSecondaryProgressValue(int amount)
increaseSecondaryProgressValue
in interface WaitingHandler
amount
- the amount to increase the value bypublic void setSecondaryProgressDialogIndeterminate(boolean intermediate)
setSecondaryProgressDialogIndeterminate
in interface WaitingHandler
intermediate
- if true, set to intermediatepublic void setRunFinished()
setRunFinished
in interface WaitingHandler
public void setRunCanceled()
setRunCanceled
in interface WaitingHandler
public void appendReport(String report, boolean includeDate, boolean addNewLine)
appendReport
in interface WaitingHandler
report
- the text to appendincludeDate
- if the date and time is to be added to the front of the textaddNewLine
- add a new line after the text?public void appendReportNewLineNoDate()
appendReportNewLineNoDate
in interface WaitingHandler
public void appendReportEndLine()
appendReportEndLine
in interface WaitingHandler
public boolean isRunCanceled()
isRunCanceled
in interface WaitingHandler
public JProgressBar getSecondaryProgressBar()
getSecondaryProgressBar
in interface WaitingHandler
public void displayMessage(String message, String title, int messageType)
displayMessage
in interface WaitingHandler
message
- the message to displaytitle
- the title of the messagemessageType
- the message type in the, e.g.,
JOptionPane.INFORMATION_MESSAGEpublic void displayHtmlMessage(JEditorPane messagePane, String title, int messageType)
displayHtmlMessage
in interface WaitingHandler
messagePane
- title
- messageType
- public void setWaitingText(String text)
setWaitingText
in interface WaitingHandler
text
- a text describing what is currently waited forpublic JProgressBar getPrimaryProgressBar()
WaitingHandler
getPrimaryProgressBar
in interface WaitingHandler
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |