git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
JAL-4239 Using own id generation to avoid Random.nextLong() not implemented in jalviewjs
[jalview.git]
/
src
/
jalview
/
io
/
HTMLOutput.java
diff --git
a/src/jalview/io/HTMLOutput.java
b/src/jalview/io/HTMLOutput.java
index
2745420
..
711c465
100644
(file)
--- a/
src/jalview/io/HTMLOutput.java
+++ b/
src/jalview/io/HTMLOutput.java
@@
-34,6
+34,9
@@
import jalview.datamodel.AlignExportSettingsAdapter;
import jalview.datamodel.AlignmentExportData;
import jalview.gui.AlignmentPanel;
import jalview.gui.IProgressIndicator;
import jalview.datamodel.AlignmentExportData;
import jalview.gui.AlignmentPanel;
import jalview.gui.IProgressIndicator;
+import jalview.io.exceptions.ImageOutputException;
+import jalview.util.IdUtils;
+import jalview.util.IdUtils.IdType;
import jalview.util.MessageManager;
public abstract class HTMLOutput implements Runnable
import jalview.util.MessageManager;
public abstract class HTMLOutput implements Runnable
@@
-67,7
+70,7
@@
public abstract class HTMLOutput implements Runnable
this.ap = ap;
this.pIndicator = ap.alignFrame;
this.description = desc;
this.ap = ap;
this.pIndicator = ap.alignFrame;
this.description = desc;
- this.pSessionId = System.currentTimeMillis();
+ this.pSessionId = IdUtils.newId(IdType.PROGRESS);
}
/**
}
/**
@@
-238,7
+241,7
@@
public abstract class HTMLOutput implements Runnable
}
else
{
}
else
{
- System.out.println(message);
+ jalview.bin.Console.outPrintln(message);
}
}
}
}
@@
-302,7
+305,13
@@
public abstract class HTMLOutput implements Runnable
return generatedFile;
}
return generatedFile;
}
- public void exportHTML(String outputFile)
+ public void exportHTML(String outputFile) throws ImageOutputException
+ {
+ exportHTML(outputFile, null);
+ }
+
+ public void exportHTML(String outputFile, String renderer)
+ throws ImageOutputException
{
setProgressMessage(MessageManager.formatMessage(
"status.exporting_alignment_as_x_file", getDescription()));
{
setProgressMessage(MessageManager.formatMessage(
"status.exporting_alignment_as_x_file", getDescription()));
@@
-332,7
+341,7
@@
public abstract class HTMLOutput implements Runnable
}
if (Jalview.isHeadlessMode())
{
}
if (Jalview.isHeadlessMode())
{
- this.run();
+ this.run(renderer);
}
else
{
}
else
{
@@
-351,4
+360,7
@@
public abstract class HTMLOutput implements Runnable
{
return description;
}
{
return description;
}
+
+ // used to pass an option such as render to run
+ public abstract void run(String string) throws ImageOutputException;
}
\ No newline at end of file
}
\ No newline at end of file