From 7641310c1fc6b3ae9c56d5bd5470fc37ea568976 Mon Sep 17 00:00:00 2001 From: Jim Procter Date: Mon, 4 Apr 2016 15:49:02 +0100 Subject: [PATCH] JAL-1551 formatting --- src/jalview/bin/JalviewLite.java | 62 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) diff --git a/src/jalview/bin/JalviewLite.java b/src/jalview/bin/JalviewLite.java index 095cfd3..13e4b7e 100644 --- a/src/jalview/bin/JalviewLite.java +++ b/src/jalview/bin/JalviewLite.java @@ -100,6 +100,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#getSelectedSequences() */ + @Override public String getSelectedSequences() { return getSelectedSequencesFrom(getDefaultTargetFrame()); @@ -110,6 +111,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#getSelectedSequences(java.lang.String) */ + @Override public String getSelectedSequences(String sep) { return getSelectedSequencesFrom(getDefaultTargetFrame(), sep); @@ -122,6 +124,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getSelectedSequencesFrom(jalview.appletgui * .AlignFrame) */ + @Override public String getSelectedSequencesFrom(AlignFrame alf) { return getSelectedSequencesFrom(alf, separator); // ""+0x00AC); @@ -134,6 +137,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getSelectedSequencesFrom(jalview.appletgui * .AlignFrame, java.lang.String) */ + @Override public String getSelectedSequencesFrom(AlignFrame alf, String sep) { StringBuffer result = new StringBuffer(""); @@ -162,6 +166,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#highlight(java.lang.String, * java.lang.String, java.lang.String) */ + @Override public void highlight(String sequenceId, String position, String alignedPosition) { @@ -175,6 +180,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#highlightIn(jalview.appletgui.AlignFrame, * java.lang.String, java.lang.String, java.lang.String) */ + @Override public void highlightIn(final AlignFrame alf, final String sequenceId, final String position, final String alignedPosition) { @@ -231,6 +237,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#select(java.lang.String, * java.lang.String) */ + @Override public void select(String sequenceIds, String columns) { selectIn(getDefaultTargetFrame(), sequenceIds, columns, separator); @@ -242,6 +249,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#select(java.lang.String, * java.lang.String, java.lang.String) */ + @Override public void select(String sequenceIds, String columns, String sep) { selectIn(getDefaultTargetFrame(), sequenceIds, columns, sep); @@ -253,6 +261,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#selectIn(jalview.appletgui.AlignFrame, * java.lang.String, java.lang.String) */ + @Override public void selectIn(AlignFrame alf, String sequenceIds, String columns) { selectIn(alf, sequenceIds, columns, separator); @@ -264,6 +273,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#selectIn(jalview.appletgui.AlignFrame, * java.lang.String, java.lang.String, java.lang.String) */ + @Override public void selectIn(final AlignFrame alf, String sequenceIds, String columns, String sep) { @@ -489,6 +499,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getSelectedSequencesAsAlignment(java.lang. * String, java.lang.String) */ + @Override public String getSelectedSequencesAsAlignment(String format, String suffix) { return getSelectedSequencesAsAlignmentFrom(getDefaultTargetFrame(), @@ -502,6 +513,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getSelectedSequencesAsAlignmentFrom(jalview * .appletgui.AlignFrame, java.lang.String, java.lang.String) */ + @Override public String getSelectedSequencesAsAlignmentFrom(AlignFrame alf, String format, String suffix) { @@ -531,6 +543,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#getAlignmentOrder() */ + @Override public String getAlignmentOrder() { return getAlignmentOrderFrom(getDefaultTargetFrame()); @@ -543,6 +556,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getAlignmentOrderFrom(jalview.appletgui.AlignFrame * ) */ + @Override public String getAlignmentOrderFrom(AlignFrame alf) { return getAlignmentOrderFrom(alf, separator); @@ -555,6 +569,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getAlignmentOrderFrom(jalview.appletgui.AlignFrame * , java.lang.String) */ + @Override public String getAlignmentOrderFrom(AlignFrame alf, String sep) { AlignmentI alorder = alf.getAlignViewport().getAlignment(); @@ -572,6 +587,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#orderBy(java.lang.String, * java.lang.String) */ + @Override public String orderBy(String order, String undoName) { return orderBy(order, undoName, separator); @@ -583,6 +599,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#orderBy(java.lang.String, * java.lang.String, java.lang.String) */ + @Override public String orderBy(String order, String undoName, String sep) { return orderAlignmentBy(getDefaultTargetFrame(), order, undoName, sep); @@ -595,6 +612,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#orderAlignmentBy(jalview.appletgui.AlignFrame, * java.lang.String, java.lang.String, java.lang.String) */ + @Override public String orderAlignmentBy(AlignFrame alf, String order, String undoName, String sep) { @@ -651,6 +669,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#getAlignment(java.lang.String) */ + @Override public String getAlignment(String format) { return getAlignmentFrom(getDefaultTargetFrame(), format, TRUE); @@ -663,6 +682,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getAlignmentFrom(jalview.appletgui.AlignFrame, * java.lang.String) */ + @Override public String getAlignmentFrom(AlignFrame alf, String format) { return getAlignmentFrom(alf, format, TRUE); @@ -674,6 +694,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#getAlignment(java.lang.String, * java.lang.String) */ + @Override public String getAlignment(String format, String suffix) { return getAlignmentFrom(getDefaultTargetFrame(), format, suffix); @@ -686,6 +707,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getAlignmentFrom(jalview.appletgui.AlignFrame, * java.lang.String, java.lang.String) */ + @Override public String getAlignmentFrom(AlignFrame alf, String format, String suffix) { @@ -708,6 +730,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#loadAnnotation(java.lang.String) */ + @Override public void loadAnnotation(String annotation) { loadAnnotationFrom(getDefaultTargetFrame(), annotation); @@ -720,6 +743,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#loadAnnotationFrom(jalview.appletgui.AlignFrame * , java.lang.String) */ + @Override public void loadAnnotationFrom(AlignFrame alf, String annotation) { if (new AnnotationFile().annotateAlignmentView(alf.getAlignViewport(), @@ -739,6 +763,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#loadAnnotation(java.lang.String) */ + @Override public void loadFeatures(String features, boolean autoenabledisplay) { loadFeaturesFrom(getDefaultTargetFrame(), features, autoenabledisplay); @@ -751,6 +776,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#loadAnnotationFrom(jalview.appletgui.AlignFrame * , java.lang.String) */ + @Override public boolean loadFeaturesFrom(AlignFrame alf, String features, boolean autoenabledisplay) { @@ -763,6 +789,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#getFeatures(java.lang.String) */ + @Override public String getFeatures(String format) { return getFeaturesFrom(getDefaultTargetFrame(), format); @@ -775,6 +802,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getFeaturesFrom(jalview.appletgui.AlignFrame, * java.lang.String) */ + @Override public String getFeaturesFrom(AlignFrame alf, String format) { return alf.outputFeatures(false, format); @@ -785,6 +813,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#getAnnotation() */ + @Override public String getAnnotation() { return getAnnotationFrom(getDefaultTargetFrame()); @@ -797,6 +826,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getAnnotationFrom(jalview.appletgui.AlignFrame * ) */ + @Override public String getAnnotationFrom(AlignFrame alf) { return alf.outputAnnotations(false); @@ -807,6 +837,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#newView() */ + @Override public AlignFrame newView() { return newViewFrom(getDefaultTargetFrame()); @@ -817,6 +848,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#newView(java.lang.String) */ + @Override public AlignFrame newView(String name) { return newViewFrom(getDefaultTargetFrame(), name); @@ -827,6 +859,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#newViewFrom(jalview.appletgui.AlignFrame) */ + @Override public AlignFrame newViewFrom(AlignFrame alf) { return alf.newView(null); @@ -838,6 +871,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#newViewFrom(jalview.appletgui.AlignFrame, * java.lang.String) */ + @Override public AlignFrame newViewFrom(AlignFrame alf, String name) { return alf.newView(name); @@ -849,6 +883,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#loadAlignment(java.lang.String, * java.lang.String) */ + @Override public AlignFrame loadAlignment(String text, String title) { AlignmentI al = null; @@ -875,6 +910,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#setMouseoverListener(java.lang.String) */ + @Override public void setMouseoverListener(String listener) { setMouseoverListener(currentAlignFrame, listener); @@ -889,6 +925,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#setMouseoverListener(jalview.appletgui.AlignFrame * , java.lang.String) */ + @Override public void setMouseoverListener(AlignFrame af, String listener) { if (listener != null) @@ -921,6 +958,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#setSelectionListener(java.lang.String) */ + @Override public void setSelectionListener(String listener) { setSelectionListener(null, listener); @@ -933,6 +971,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#setSelectionListener(jalview.appletgui.AlignFrame * , java.lang.String) */ + @Override public void setSelectionListener(AlignFrame af, String listener) { if (listener != null) @@ -971,6 +1010,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#setStructureListener(java.lang.String, * java.lang.String) */ + @Override public void setStructureListener(String listener, String modelSet) { if (listener != null) @@ -1004,6 +1044,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#removeJavascriptListener(jalview.appletgui * .AlignFrame, java.lang.String) */ + @Override public void removeJavascriptListener(AlignFrame af, String listener) { if (listener != null) @@ -1053,12 +1094,14 @@ public class JalviewLite extends Applet implements } } + @Override public void stop() { System.err.println("Applet " + getName() + " stop()."); tidyUp(); } + @Override public void destroy() { System.err.println("Applet " + getName() + " destroy()."); @@ -1115,6 +1158,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#mouseOverStructure(java.lang.String, * java.lang.String, java.lang.String) */ + @Override public void mouseOverStructure(final String pdbResNum, final String chain, final String pdbfile) { @@ -1152,6 +1196,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#scrollViewToIn(jalview.appletgui.AlignFrame, * java.lang.String, java.lang.String) */ + @Override public void scrollViewToIn(final AlignFrame alf, final String topRow, final String leftHandColumn) { @@ -1491,6 +1536,7 @@ public class JalviewLite extends Applet implements add(launcher); launcher.addActionListener(new java.awt.event.ActionListener() { + @Override public void actionPerformed(ActionEvent e) { LoadingThread loader = new LoadingThread(file, file2, @@ -1613,6 +1659,7 @@ public class JalviewLite extends Applet implements frame.setTitle(title); frame.addWindowListener(new WindowAdapter() { + @Override public void windowClosing(WindowEvent e) { if (frame instanceof AlignFrame) @@ -1637,6 +1684,7 @@ public class JalviewLite extends Applet implements frame.dispose(); } + @Override public void windowActivated(WindowEvent e) { if (frame instanceof AlignFrame) @@ -1674,6 +1722,7 @@ public class JalviewLite extends Applet implements * @param g * graphics context */ + @Override public void paint(Graphics g) { if (!fileFound) @@ -1725,6 +1774,7 @@ public class JalviewLite extends Applet implements { private boolean running = false; + @Override public void run() { if (running || checkedForJmol) @@ -1869,6 +1919,7 @@ public class JalviewLite extends Applet implements applet = _applet; } + @Override public void run() { LoadJmolThread jmolchecker = new LoadJmolThread(); @@ -2569,6 +2620,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#getFeatureGroups() */ + @Override public String getFeatureGroups() { String lst = arrayToSeparatorList(getDefaultTargetFrame() @@ -2583,6 +2635,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getFeatureGroupsOn(jalview.appletgui.AlignFrame * ) */ + @Override public String getFeatureGroupsOn(AlignFrame alf) { String lst = arrayToSeparatorList(alf.getFeatureGroups()); @@ -2594,6 +2647,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#getFeatureGroupsOfState(boolean) */ + @Override public String getFeatureGroupsOfState(boolean visible) { return arrayToSeparatorList(getDefaultTargetFrame() @@ -2607,6 +2661,7 @@ public class JalviewLite extends Applet implements * jalview.bin.JalviewLiteJsApi#getFeatureGroupsOfStateOn(jalview.appletgui * .AlignFrame, boolean) */ + @Override public String getFeatureGroupsOfStateOn(AlignFrame alf, boolean visible) { return arrayToSeparatorList(alf.getFeatureGroupsOfState(visible)); @@ -2618,6 +2673,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#setFeatureGroupStateOn(jalview.appletgui. * AlignFrame, java.lang.String, boolean) */ + @Override public void setFeatureGroupStateOn(final AlignFrame alf, final String groups, boolean state) { @@ -2639,6 +2695,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#setFeatureGroupState(java.lang.String, * boolean) */ + @Override public void setFeatureGroupState(String groups, boolean state) { setFeatureGroupStateOn(getDefaultTargetFrame(), groups, state); @@ -2649,6 +2706,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#getSeparator() */ + @Override public String getSeparator() { return separator; @@ -2659,6 +2717,7 @@ public class JalviewLite extends Applet implements * * @see jalview.bin.JalviewLiteJsApi#setSeparator(java.lang.String) */ + @Override public void setSeparator(String separator) { if (separator == null || separator.length() < 1) @@ -2703,6 +2762,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#addPdbFile(jalview.appletgui.AlignFrame, * java.lang.String, java.lang.String, java.lang.String) */ + @Override public boolean addPdbFile(AlignFrame alFrame, String sequenceId, String pdbEntryString, String pdbFile) { @@ -2719,6 +2779,7 @@ public class JalviewLite extends Applet implements return alignPdbStructures; } + @Override public void start() { // callInitCallback(); @@ -2752,6 +2813,7 @@ public class JalviewLite extends Applet implements * @see jalview.bin.JalviewLiteJsApi#getJsMessage(java.lang.String, * java.lang.String) */ + @Override public String getJsMessage(String messageclass, String viewId) { Hashtable msgset = jsmessages.get(messageclass); -- 1.7.10.2