From 1a8f953dd71a9e319e910261927f269d69b4692c Mon Sep 17 00:00:00 2001 From: jprocter Date: Fri, 7 Dec 2012 13:47:06 +0000 Subject: [PATCH] proxy commit for Anne Menard throw generic exceptions (just for record - finessed by 2a7ae58b8b7d619b73e8a25654fa3a12414cfd9a JAL-1140) --- src/MCview/PDBViewer.java | 10 +-------- src/MCview/PDBfile.java | 14 +++--------- src/jalview/appletgui/AlignFrame.java | 5 +---- src/jalview/gui/AssociatePdbFileWithSeq.java | 10 ++------- src/jalview/gui/PopupMenu.java | 2 +- src/jalview/io/AlignFile.java | 31 +++++--------------------- src/jalview/io/BLCFile.java | 15 +++---------- src/jalview/io/ClustalFile.java | 4 ++-- src/jalview/io/FastaFile.java | 15 +++---------- src/jalview/io/FeaturesFile.java | 21 +++-------------- src/jalview/io/JPredFile.java | 25 +++++---------------- src/jalview/io/MSFfile.java | 15 +++---------- src/jalview/io/PIRFile.java | 4 ++-- src/jalview/io/PfamFile.java | 4 ++-- src/jalview/io/PileUpfile.java | 15 +++---------- src/jalview/io/SimpleBlastFile.java | 4 ++-- src/jalview/io/StockholmFile.java | 6 ++--- src/jalview/io/TCoffeeScoreFile.java | 4 ++-- test/jalview/io/TCoffeeScoreFileTest.java | 12 +++++----- 19 files changed, 53 insertions(+), 163 deletions(-) diff --git a/src/MCview/PDBViewer.java b/src/MCview/PDBViewer.java index b3aae51..e79c017 100755 --- a/src/MCview/PDBViewer.java +++ b/src/MCview/PDBViewer.java @@ -21,14 +21,6 @@ import java.io.*; import java.awt.event.*; import javax.swing.*; -import javax.xml.parsers.ParserConfigurationException; - -import org.xml.sax.SAXException; - -import fr.orsay.lri.varna.exceptions.ExceptionFileFormatOrSyntax; -import fr.orsay.lri.varna.exceptions.ExceptionLoadingFailed; -import fr.orsay.lri.varna.exceptions.ExceptionPermissionDenied; -import fr.orsay.lri.varna.exceptions.ExceptionUnmatchedClosingParentheses; import jalview.datamodel.*; import jalview.gui.*; @@ -57,7 +49,7 @@ public class PDBViewer extends JInternalFrame implements Runnable String tmpPDBFile; public PDBViewer(PDBEntry pdbentry, SequenceI[] seq, String[] chains, - AlignmentPanel ap, String protocol) throws ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + AlignmentPanel ap, String protocol) throws Exception { this.pdbentry = pdbentry; diff --git a/src/MCview/PDBfile.java b/src/MCview/PDBfile.java index 1b3aa8b..fb14a46 100755 --- a/src/MCview/PDBfile.java +++ b/src/MCview/PDBfile.java @@ -22,14 +22,6 @@ import java.util.*; import java.awt.*; -import javax.xml.parsers.ParserConfigurationException; - -import org.xml.sax.SAXException; - -import fr.orsay.lri.varna.exceptions.ExceptionFileFormatOrSyntax; -import fr.orsay.lri.varna.exceptions.ExceptionLoadingFailed; -import fr.orsay.lri.varna.exceptions.ExceptionPermissionDenied; -import fr.orsay.lri.varna.exceptions.ExceptionUnmatchedClosingParentheses; import jalview.analysis.AlignSeq; import jalview.datamodel.*; @@ -47,12 +39,12 @@ public class PDBfile extends jalview.io.AlignFile */ boolean VisibleChainAnnotation = false; - public PDBfile(String inFile, String inType) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public PDBfile(String inFile, String inType) throws Exception { super(inFile, inType); } - public PDBfile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public PDBfile(FileParse source) throws Exception { super(source); } @@ -62,7 +54,7 @@ public class PDBfile extends jalview.io.AlignFile return null; } - public void parse() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException + public void parse() throws Exception { // TODO set the filename sensibly - try using data source name. id = safeName(getDataName()); diff --git a/src/jalview/appletgui/AlignFrame.java b/src/jalview/appletgui/AlignFrame.java index 6826266..e5bd3d6 100644 --- a/src/jalview/appletgui/AlignFrame.java +++ b/src/jalview/appletgui/AlignFrame.java @@ -3732,10 +3732,7 @@ public class AlignFrame extends EmbmenuFrame implements ActionListener, * @throws InterruptedException * @throws ExceptionUnmatchedClosingParentheses */ - public boolean loadScoreFile(String source) throws IOException, - ExceptionFileFormatOrSyntax, ParserConfigurationException, - SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, - InterruptedException, ExceptionUnmatchedClosingParentheses + public boolean loadScoreFile(String source) throws Exception { TCoffeeScoreFile file = new TCoffeeScoreFile(source, diff --git a/src/jalview/gui/AssociatePdbFileWithSeq.java b/src/jalview/gui/AssociatePdbFileWithSeq.java index 22c891d..ef7dad0 100644 --- a/src/jalview/gui/AssociatePdbFileWithSeq.java +++ b/src/jalview/gui/AssociatePdbFileWithSeq.java @@ -43,15 +43,9 @@ public class AssociatePdbFileWithSeq * assocate the given PDB file with * @param choice * @param sequence - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws IOException */ - public PDBEntry associatePdbWithSeq(String choice, String protocol, SequenceI sequence, boolean prompt) throws ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public PDBEntry associatePdbWithSeq(String choice, String protocol, SequenceI sequence, boolean prompt) throws Exception { PDBEntry entry = new PDBEntry(); try diff --git a/src/jalview/gui/PopupMenu.java b/src/jalview/gui/PopupMenu.java index 3b43e6b..ef19521 100644 --- a/src/jalview/gui/PopupMenu.java +++ b/src/jalview/gui/PopupMenu.java @@ -1984,7 +1984,7 @@ public class PopupMenu extends JPopupMenu oal = null; } - public void pdbFromFile_actionPerformed() throws ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public void pdbFromFile_actionPerformed() throws IOException { jalview.io.JalviewFileChooser chooser = new jalview.io.JalviewFileChooser( jalview.bin.Cache.getProperty("LAST_DIRECTORY")); diff --git a/src/jalview/io/AlignFile.java b/src/jalview/io/AlignFile.java index cfd37b0..c0f8531 100755 --- a/src/jalview/io/AlignFile.java +++ b/src/jalview/io/AlignFile.java @@ -85,15 +85,9 @@ public abstract class AlignFile extends FileParse * Filename to read from. * @param type * What type of file to read from (File, URL) - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws Exception */ - public AlignFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public AlignFile(String inFile, String type) throws Exception { super(inFile, type); initData(); @@ -110,16 +104,9 @@ public abstract class AlignFile extends FileParse * off. * * @param source - * @throws IOException - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws Exception */ - public AlignFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public AlignFile(FileParse source) throws Exception { super(source); initData(); @@ -264,15 +251,9 @@ public abstract class AlignFile extends FileParse /** * This method must be implemented to parse the contents of the file. - * @throws ExceptionFileFormatOrSyntax - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + */ - public abstract void parse() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses; + public abstract void parse() throws Exception; /** * Print out in alignment file format the Sequences in the seqs Vector. diff --git a/src/jalview/io/BLCFile.java b/src/jalview/io/BLCFile.java index b5617c6..71c95b5 100755 --- a/src/jalview/io/BLCFile.java +++ b/src/jalview/io/BLCFile.java @@ -55,23 +55,14 @@ public class BLCFile extends AlignFile * DOCUMENT ME! * @param type * DOCUMENT ME! - * - * @throws IOException - * DOCUMENT ME! - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws Exception */ - public BLCFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public BLCFile(String inFile, String type) throws Exception { super(inFile, type); } - public BLCFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public BLCFile(FileParse source) throws Exception { super(source); } diff --git a/src/jalview/io/ClustalFile.java b/src/jalview/io/ClustalFile.java index d1225c4..c789139 100755 --- a/src/jalview/io/ClustalFile.java +++ b/src/jalview/io/ClustalFile.java @@ -39,12 +39,12 @@ public class ClustalFile extends AlignFile { } - public ClustalFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public ClustalFile(String inFile, String type) throws Exception { super(inFile, type); } - public ClustalFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public ClustalFile(FileParse source) throws Exception { super(source); } diff --git a/src/jalview/io/FastaFile.java b/src/jalview/io/FastaFile.java index f413540..f809443 100755 --- a/src/jalview/io/FastaFile.java +++ b/src/jalview/io/FastaFile.java @@ -59,23 +59,14 @@ public class FastaFile extends AlignFile * DOCUMENT ME! * @param type * DOCUMENT ME! - * - * @throws IOException - * DOCUMENT ME! - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws Exception */ - public FastaFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public FastaFile(String inFile, String type) throws Exception { super(inFile, type); } - public FastaFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public FastaFile(FileParse source) throws Exception { super(source); } diff --git a/src/jalview/io/FeaturesFile.java b/src/jalview/io/FeaturesFile.java index afbd223..c65bded 100755 --- a/src/jalview/io/FeaturesFile.java +++ b/src/jalview/io/FeaturesFile.java @@ -65,29 +65,14 @@ public class FeaturesFile extends AlignFile * DOCUMENT ME! * @param type * DOCUMENT ME! - * - * @throws IOException - * DOCUMENT ME! - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws Exception */ - public FeaturesFile(String inFile, String type) throws IOException, - ExceptionFileFormatOrSyntax, ParserConfigurationException, - SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, - InterruptedException, ExceptionUnmatchedClosingParentheses + public FeaturesFile(String inFile, String type) throws Exception { super(inFile, type); } - public FeaturesFile(FileParse source) throws IOException, - ExceptionFileFormatOrSyntax, ParserConfigurationException, - SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, - InterruptedException, ExceptionUnmatchedClosingParentheses + public FeaturesFile(FileParse source) throws Exception { super(source); } diff --git a/src/jalview/io/JPredFile.java b/src/jalview/io/JPredFile.java index 509758b..fc77ad6 100755 --- a/src/jalview/io/JPredFile.java +++ b/src/jalview/io/JPredFile.java @@ -72,23 +72,14 @@ public class JPredFile extends AlignFile * DOCUMENT ME! * @param type * DOCUMENT ME! - * - * @throws IOException - * DOCUMENT ME! - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws Exception */ - public JPredFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public JPredFile(String inFile, String type) throws Exception { super(inFile, type); } - public JPredFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public JPredFile(FileParse source) throws Exception { super(source); } @@ -363,15 +354,9 @@ public class JPredFile extends AlignFile * * @param args * DOCUMENT ME! - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws Exception */ - public static void main(String[] args) throws ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public static void main(String[] args) throws Exception { try { diff --git a/src/jalview/io/MSFfile.java b/src/jalview/io/MSFfile.java index c3ee382..dcbe37d 100755 --- a/src/jalview/io/MSFfile.java +++ b/src/jalview/io/MSFfile.java @@ -55,23 +55,14 @@ public class MSFfile extends AlignFile * DOCUMENT ME! * @param type * DOCUMENT ME! - * - * @throws IOException - * DOCUMENT ME! - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws Exception */ - public MSFfile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public MSFfile(String inFile, String type) throws Exception { super(inFile, type); } - public MSFfile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public MSFfile(FileParse source) throws Exception { super(source); } diff --git a/src/jalview/io/PIRFile.java b/src/jalview/io/PIRFile.java index cdd0b98..d910b0f 100755 --- a/src/jalview/io/PIRFile.java +++ b/src/jalview/io/PIRFile.java @@ -41,12 +41,12 @@ public class PIRFile extends AlignFile { } - public PIRFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public PIRFile(String inFile, String type) throws Exception { super(inFile, type); } - public PIRFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public PIRFile(FileParse source) throws Exception { super(source); } diff --git a/src/jalview/io/PfamFile.java b/src/jalview/io/PfamFile.java index af91390..30b5076 100755 --- a/src/jalview/io/PfamFile.java +++ b/src/jalview/io/PfamFile.java @@ -39,12 +39,12 @@ public class PfamFile extends AlignFile { } - public PfamFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public PfamFile(String inFile, String type) throws Exception { super(inFile, type); } - public PfamFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public PfamFile(FileParse source) throws Exception { super(source); } diff --git a/src/jalview/io/PileUpfile.java b/src/jalview/io/PileUpfile.java index 3fffab3..95fb203 100755 --- a/src/jalview/io/PileUpfile.java +++ b/src/jalview/io/PileUpfile.java @@ -63,23 +63,14 @@ public class PileUpfile extends MSFfile * DOCUMENT ME! * @param type * DOCUMENT ME! - * - * @throws IOException - * DOCUMENT ME! - * @throws SAXException - * @throws ParserConfigurationException - * @throws ExceptionFileFormatOrSyntax - * @throws ExceptionLoadingFailed - * @throws ExceptionPermissionDenied - * @throws InterruptedException - * @throws ExceptionUnmatchedClosingParentheses + * @throws Exception */ - public PileUpfile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public PileUpfile(String inFile, String type) throws Exception { super(inFile, type); } - public PileUpfile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public PileUpfile(FileParse source) throws Exception { super(source); } diff --git a/src/jalview/io/SimpleBlastFile.java b/src/jalview/io/SimpleBlastFile.java index 9256283..53d2790 100644 --- a/src/jalview/io/SimpleBlastFile.java +++ b/src/jalview/io/SimpleBlastFile.java @@ -54,12 +54,12 @@ public class SimpleBlastFile extends AlignFile { } - public SimpleBlastFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public SimpleBlastFile(String inFile, String type) throws Exception { super(inFile, type); } - public SimpleBlastFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public SimpleBlastFile(FileParse source) throws Exception { super(source); } diff --git a/src/jalview/io/StockholmFile.java b/src/jalview/io/StockholmFile.java index 07a5c80..86cb4ae 100644 --- a/src/jalview/io/StockholmFile.java +++ b/src/jalview/io/StockholmFile.java @@ -62,12 +62,12 @@ public class StockholmFile extends AlignFile { } - public StockholmFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public StockholmFile(String inFile, String type) throws Exception { super(inFile, type); } - public StockholmFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public StockholmFile(FileParse source) throws Exception { super(source); } @@ -85,7 +85,7 @@ public class StockholmFile extends AlignFile * If there is an error with the input file * @throws ExceptionUnmatchedClosingParentheses */ - public void parse() throws IOException, ExceptionUnmatchedClosingParentheses + public void parse() { FileReader fr = null; fr = new FileReader(inFile); diff --git a/src/jalview/io/TCoffeeScoreFile.java b/src/jalview/io/TCoffeeScoreFile.java index 56994ae..9776b56 100644 --- a/src/jalview/io/TCoffeeScoreFile.java +++ b/src/jalview/io/TCoffeeScoreFile.java @@ -97,13 +97,13 @@ import fr.orsay.lri.varna.exceptions.ExceptionUnmatchedClosingParentheses; */ public class TCoffeeScoreFile extends AlignFile { - public TCoffeeScoreFile(String inFile, String type) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public TCoffeeScoreFile(String inFile, String type) throws Exception { super(inFile, type); } - public TCoffeeScoreFile(FileParse source) throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses + public TCoffeeScoreFile(FileParse source) throws Exception { super(source); } diff --git a/test/jalview/io/TCoffeeScoreFileTest.java b/test/jalview/io/TCoffeeScoreFileTest.java index ce23728..78de7bf 100644 --- a/test/jalview/io/TCoffeeScoreFileTest.java +++ b/test/jalview/io/TCoffeeScoreFileTest.java @@ -42,7 +42,7 @@ public class TCoffeeScoreFileTest { final static File ALIGN_FILE = new File("test/jalview/io/tcoffee.fasta_aln"); @Test - public void testReadHeader() throws IOException, FileNotFoundException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses { + public void testReadHeader() throws Exception { TCoffeeScoreFile scoreFile = new TCoffeeScoreFile(SCORE_FILE.getPath(),AppletFormatAdapter.FILE); assertTrue(scoreFile.getWarningMessage(),scoreFile.isValid()); @@ -64,7 +64,7 @@ public class TCoffeeScoreFileTest { @Test - public void testWrongFile() throws ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses { + public void testWrongFile() throws Exception { try { TCoffeeScoreFile result = new TCoffeeScoreFile(ALIGN_FILE.getPath(), FormatAdapter.FILE); assertFalse(result.isValid()); @@ -76,7 +76,7 @@ public class TCoffeeScoreFileTest { } @Test - public void testHeightAndWidth() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses { + public void testHeightAndWidth() throws Exception { TCoffeeScoreFile result = new TCoffeeScoreFile(SCORE_FILE.getPath(), FormatAdapter.FILE); assertTrue(result.isValid()); assertEquals( 8, result.getHeight() ); @@ -116,7 +116,7 @@ public class TCoffeeScoreFileTest { } @Test - public void testParse() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses { + public void testParse() throws Exception { TCoffeeScoreFile parser = new TCoffeeScoreFile(SCORE_FILE.getPath(), FormatAdapter.FILE); @@ -133,7 +133,7 @@ public class TCoffeeScoreFileTest { @Test - public void testGetAsList() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses { + public void testGetAsList() throws Exception { TCoffeeScoreFile parser = new TCoffeeScoreFile(SCORE_FILE.getPath(),FormatAdapter.FILE); assertTrue(parser.getWarningMessage(),parser.isValid()); @@ -152,7 +152,7 @@ public class TCoffeeScoreFileTest { @Test - public void testGetAsArray() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed, InterruptedException, ExceptionUnmatchedClosingParentheses { + public void testGetAsArray() throws Exception { TCoffeeScoreFile parser = new TCoffeeScoreFile(SCORE_FILE.getPath(),FormatAdapter.FILE); assertTrue(parser.getWarningMessage(),parser.isValid()); -- 1.7.10.2