clean up
authorcmzmasek@gmail.com <cmzmasek@gmail.com@ca865154-3058-d1c3-3e42-d8f55a55bdbd>
Thu, 3 Mar 2011 18:37:12 +0000 (18:37 +0000)
committercmzmasek@gmail.com <cmzmasek@gmail.com@ca865154-3058-d1c3-3e42-d8f55a55bdbd>
Thu, 3 Mar 2011 18:37:12 +0000 (18:37 +0000)
296 files changed:
forester/java/src/org/forester/analysis/AncestralTaxonomyInference.java
forester/java/src/org/forester/application/confadd.java
forester/java/src/org/forester/application/count_support.java
forester/java/src/org/forester/application/decorator.java
forester/java/src/org/forester/application/get_distances.java
forester/java/src/org/forester/application/goac.java
forester/java/src/org/forester/application/nhx_too.java
forester/java/src/org/forester/application/nj.java
forester/java/src/org/forester/application/obo_tool.java
forester/java/src/org/forester/application/pccx.java
forester/java/src/org/forester/application/pfam2go_extractor.java
forester/java/src/org/forester/application/pfam_go.java
forester/java/src/org/forester/application/pfamacc2go.java
forester/java/src/org/forester/application/pfamacc2pfamid.java
forester/java/src/org/forester/application/phyloxml_converter.java
forester/java/src/org/forester/application/printAllSpecies.java
forester/java/src/org/forester/application/printSameOrder.java
forester/java/src/org/forester/application/rio.java
forester/java/src/org/forester/application/sdi.java
forester/java/src/org/forester/application/sdi_dir.java
forester/java/src/org/forester/application/sdi_r.java
forester/java/src/org/forester/application/sdix.java
forester/java/src/org/forester/application/simple_node_processor.java
forester/java/src/org/forester/application/strip.java
forester/java/src/org/forester/application/support_statistics.java
forester/java/src/org/forester/application/support_transfer.java
forester/java/src/org/forester/application/surf_paup.java
forester/java/src/org/forester/application/surfacing.java
forester/java/src/org/forester/application/surfacing_hmmpfam.java
forester/java/src/org/forester/application/surfacing_old.java
forester/java/src/org/forester/application/ta.java
forester/java/src/org/forester/archaeopteryx/AncestralTaxonomyInferrer.java
forester/java/src/org/forester/archaeopteryx/Archaeopteryx.java
forester/java/src/org/forester/archaeopteryx/ArchaeopteryxA.java
forester/java/src/org/forester/archaeopteryx/ArchaeopteryxE.java
forester/java/src/org/forester/archaeopteryx/Blast.java
forester/java/src/org/forester/archaeopteryx/ColorSchemeChooser.java
forester/java/src/org/forester/archaeopteryx/Configuration.java
forester/java/src/org/forester/archaeopteryx/Constants.java
forester/java/src/org/forester/archaeopteryx/ControlPanel.java
forester/java/src/org/forester/archaeopteryx/FontChooser.java
forester/java/src/org/forester/archaeopteryx/ImageLoader.java
forester/java/src/org/forester/archaeopteryx/MainFrame.java
forester/java/src/org/forester/archaeopteryx/MainFrameApplet.java
forester/java/src/org/forester/archaeopteryx/MainFrameApplication.java
forester/java/src/org/forester/archaeopteryx/MainPanel.java
forester/java/src/org/forester/archaeopteryx/MainPanelApplets.java
forester/java/src/org/forester/archaeopteryx/MainPanelEdit.java
forester/java/src/org/forester/archaeopteryx/MouseListener.java
forester/java/src/org/forester/archaeopteryx/NodeEditPanel.java
forester/java/src/org/forester/archaeopteryx/NodeFrame.java
forester/java/src/org/forester/archaeopteryx/NodePanel.java
forester/java/src/org/forester/archaeopteryx/Options.java
forester/java/src/org/forester/archaeopteryx/PdfExporter.java
forester/java/src/org/forester/archaeopteryx/PhyloInferenceDialog.java
forester/java/src/org/forester/archaeopteryx/PhylogeneticInferenceOptions.java
forester/java/src/org/forester/archaeopteryx/PhylogeneticInferrer.java
forester/java/src/org/forester/archaeopteryx/Printer.java
forester/java/src/org/forester/archaeopteryx/TaxonomyDataObtainer.java
forester/java/src/org/forester/archaeopteryx/TextFrame.java
forester/java/src/org/forester/archaeopteryx/TreeColorSet.java
forester/java/src/org/forester/archaeopteryx/TreeFontSet.java
forester/java/src/org/forester/archaeopteryx/TreePanel.java
forester/java/src/org/forester/archaeopteryx/UrlTreeReader.java
forester/java/src/org/forester/archaeopteryx/Util.java
forester/java/src/org/forester/archaeopteryx/WebLink.java
forester/java/src/org/forester/archaeopteryx/phylogeny/data/RenderableDomainArchitecture.java
forester/java/src/org/forester/archaeopteryx/phylogeny/data/RenderablePhylogenyData.java
forester/java/src/org/forester/archaeopteryx/phylogeny/data/RenderableVector.java
forester/java/src/org/forester/archaeopteryx/webservices/BasicPhylogeniesWebserviceClient.java
forester/java/src/org/forester/archaeopteryx/webservices/PhylogeniesWebserviceClient.java
forester/java/src/org/forester/archaeopteryx/webservices/WebserviceUtil.java
forester/java/src/org/forester/archaeopteryx/webservices/WebservicesManager.java
forester/java/src/org/forester/datastructures/Queue.java
forester/java/src/org/forester/development/AbstractRenderer.java
forester/java/src/org/forester/development/DevelopmentTools.java
forester/java/src/org/forester/development/HmmerRest.java
forester/java/src/org/forester/development/MsaRenderer.java
forester/java/src/org/forester/development/ResidueRenderer.java
forester/java/src/org/forester/development/Test.java
forester/java/src/org/forester/evoinference/TestPhylogenyReconstruction.java
forester/java/src/org/forester/evoinference/distance/NeighborJoining.java
forester/java/src/org/forester/evoinference/distance/PairwiseDistanceCalculator.java
forester/java/src/org/forester/evoinference/matrix/character/BasicCharacterStateMatrix.java
forester/java/src/org/forester/evoinference/matrix/character/CharacterStateMatrix.java
forester/java/src/org/forester/evoinference/matrix/character/DiscreteState.java
forester/java/src/org/forester/evoinference/matrix/distance/BasicSymmetricalDistanceMatrix.java
forester/java/src/org/forester/evoinference/matrix/distance/DistanceMatrix.java
forester/java/src/org/forester/evoinference/parsimony/DolloParsimony.java
forester/java/src/org/forester/evoinference/parsimony/FitchParsimony.java
forester/java/src/org/forester/evoinference/parsimony/SankoffParsimony.java
forester/java/src/org/forester/evoinference/tools/BootstrapResampler.java
forester/java/src/org/forester/go/BasicGoRelationship.java
forester/java/src/org/forester/go/BasicGoSubset.java
forester/java/src/org/forester/go/BasicGoTerm.java
forester/java/src/org/forester/go/BasicGoXRef.java
forester/java/src/org/forester/go/GoId.java
forester/java/src/org/forester/go/GoNameSpace.java
forester/java/src/org/forester/go/GoRelationship.java
forester/java/src/org/forester/go/GoSubset.java
forester/java/src/org/forester/go/GoTerm.java
forester/java/src/org/forester/go/GoUtils.java
forester/java/src/org/forester/go/GoXRef.java
forester/java/src/org/forester/go/Mapping.java
forester/java/src/org/forester/go/OBOparser.java
forester/java/src/org/forester/go/PfamToGoMapping.java
forester/java/src/org/forester/go/TestGo.java
forester/java/src/org/forester/go/etc/MetaOntologizer.java
forester/java/src/org/forester/go/etc/OntologizerResult.java
forester/java/src/org/forester/io/parsers/FastaParser.java
forester/java/src/org/forester/io/parsers/GeneralMsaParser.java
forester/java/src/org/forester/io/parsers/HmmPfamOutputParser.java
forester/java/src/org/forester/io/parsers/HmmscanPerDomainTableParser.java
forester/java/src/org/forester/io/parsers/PhylogenyParser.java
forester/java/src/org/forester/io/parsers/SymmetricalDistanceMatrixParser.java
forester/java/src/org/forester/io/parsers/nexus/NexusCharactersParser.java
forester/java/src/org/forester/io/parsers/nexus/NexusConstants.java
forester/java/src/org/forester/io/parsers/nexus/NexusFormatException.java
forester/java/src/org/forester/io/parsers/nexus/NexusPhylogeniesParser.java
forester/java/src/org/forester/io/parsers/nexus/PaupLogParser.java
forester/java/src/org/forester/io/parsers/nhx/NHXFormatException.java
forester/java/src/org/forester/io/parsers/nhx/NHXParser.java
forester/java/src/org/forester/io/parsers/nhx/NHXtags.java
forester/java/src/org/forester/io/parsers/phyloxml/PhyloXmlDataFormatException.java
forester/java/src/org/forester/io/parsers/phyloxml/PhyloXmlException.java
forester/java/src/org/forester/io/parsers/phyloxml/PhyloXmlHandler.java
forester/java/src/org/forester/io/parsers/phyloxml/PhyloXmlMapping.java
forester/java/src/org/forester/io/parsers/phyloxml/PhyloXmlParser.java
forester/java/src/org/forester/io/parsers/phyloxml/PhyloXmlUtil.java
forester/java/src/org/forester/io/parsers/phyloxml/XmlElement.java
forester/java/src/org/forester/io/parsers/phyloxml/data/AccessionParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/AnnotationParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/BinaryCharactersParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/BranchWidthParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/ColorParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/ConfidenceParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/DateParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/DistributionParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/EventParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/IdentifierParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/PointParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/PolygonParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/PropertyParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/ReferenceParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/SequenceRelationParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/TaxonomyParser.java
forester/java/src/org/forester/io/parsers/phyloxml/data/UriParser.java
forester/java/src/org/forester/io/parsers/tol/TolParser.java
forester/java/src/org/forester/io/parsers/tol/TolXmlHandler.java
forester/java/src/org/forester/io/parsers/util/ParserUtils.java
forester/java/src/org/forester/io/parsers/util/PhylogenyParserException.java
forester/java/src/org/forester/io/writers/PhyloXmlNodeWriter.java
forester/java/src/org/forester/io/writers/PhylogenyWriter.java
forester/java/src/org/forester/msa/BasicMsa.java
forester/java/src/org/forester/msa/Mafft.java
forester/java/src/org/forester/msa/MafftOLD.java
forester/java/src/org/forester/msa/Msa.java
forester/java/src/org/forester/msa/MsaFormatException.java
forester/java/src/org/forester/msa/MsaInferrer.java
forester/java/src/org/forester/msa/MsaTools.java
forester/java/src/org/forester/msa/ResampleableMsa.java
forester/java/src/org/forester/pccx/BasicExternalNodeBasedCoverageExtender.java
forester/java/src/org/forester/pccx/BranchCountingBasedScoringMethod.java
forester/java/src/org/forester/pccx/BranchLengthBasedScoringMethod.java
forester/java/src/org/forester/pccx/Coverage.java
forester/java/src/org/forester/pccx/CoverageCalculationMethod.java
forester/java/src/org/forester/pccx/CoverageCalculationOptions.java
forester/java/src/org/forester/pccx/CoverageCalculator.java
forester/java/src/org/forester/pccx/CoverageExtender.java
forester/java/src/org/forester/pccx/ExternalNodeBasedCoverage.java
forester/java/src/org/forester/pccx/ExternalNodeBasedCoverageMethod.java
forester/java/src/org/forester/pccx/ExternalNodeBasedCoverageMethodOptions.java
forester/java/src/org/forester/pccx/LogBranchLengthBasedScoringMethod.java
forester/java/src/org/forester/pccx/ModelingUtils.java
forester/java/src/org/forester/pccx/ScoringMethodForExternalNode.java
forester/java/src/org/forester/pccx/TestPccx.java
forester/java/src/org/forester/phylogeny/Edge.java
forester/java/src/org/forester/phylogeny/Phylogeny.java
forester/java/src/org/forester/phylogeny/PhylogenyBranch.java
forester/java/src/org/forester/phylogeny/PhylogenyMethods.java
forester/java/src/org/forester/phylogeny/PhylogenyNode.java
forester/java/src/org/forester/phylogeny/PhylogenyNodeI.java
forester/java/src/org/forester/phylogeny/data/Accession.java
forester/java/src/org/forester/phylogeny/data/Annotation.java
forester/java/src/org/forester/phylogeny/data/BinaryCharacters.java
forester/java/src/org/forester/phylogeny/data/BranchData.java
forester/java/src/org/forester/phylogeny/data/BranchWidth.java
forester/java/src/org/forester/phylogeny/data/Confidence.java
forester/java/src/org/forester/phylogeny/data/Date.java
forester/java/src/org/forester/phylogeny/data/Distribution.java
forester/java/src/org/forester/phylogeny/data/DomainArchitecture.java
forester/java/src/org/forester/phylogeny/data/Event.java
forester/java/src/org/forester/phylogeny/data/Identifier.java
forester/java/src/org/forester/phylogeny/data/MultipleUris.java
forester/java/src/org/forester/phylogeny/data/NodeData.java
forester/java/src/org/forester/phylogeny/data/PhylogenyData.java
forester/java/src/org/forester/phylogeny/data/PhylogenyDataUtil.java
forester/java/src/org/forester/phylogeny/data/Polygon.java
forester/java/src/org/forester/phylogeny/data/PropertiesMap.java
forester/java/src/org/forester/phylogeny/data/Property.java
forester/java/src/org/forester/phylogeny/data/ProteinDomain.java
forester/java/src/org/forester/phylogeny/data/Reference.java
forester/java/src/org/forester/phylogeny/data/Sequence.java
forester/java/src/org/forester/phylogeny/data/SequenceRelation.java
forester/java/src/org/forester/phylogeny/data/Taxonomy.java
forester/java/src/org/forester/phylogeny/data/Uri.java
forester/java/src/org/forester/phylogeny/factories/BasicPhylogenyFactory.java
forester/java/src/org/forester/phylogeny/factories/ParserBasedPhylogenyFactory.java
forester/java/src/org/forester/phylogeny/factories/PhylogenyFactory.java
forester/java/src/org/forester/phylogeny/iterators/ChildNodeIteratorForward.java
forester/java/src/org/forester/phylogeny/iterators/ExternalForwardIterator.java
forester/java/src/org/forester/phylogeny/iterators/LevelOrderTreeIterator.java
forester/java/src/org/forester/phylogeny/iterators/PhylogenyNodeIterator.java
forester/java/src/org/forester/phylogeny/iterators/PostOrderStackObject.java
forester/java/src/org/forester/phylogeny/iterators/PostorderTreeIterator.java
forester/java/src/org/forester/phylogeny/iterators/PreorderTreeIterator.java
forester/java/src/org/forester/sdi/DistanceCalculator.java
forester/java/src/org/forester/sdi/GSDI.java
forester/java/src/org/forester/sdi/ORcount.java
forester/java/src/org/forester/sdi/RIO.java
forester/java/src/org/forester/sdi/RIOn.java
forester/java/src/org/forester/sdi/SDI.java
forester/java/src/org/forester/sdi/SDIR.java
forester/java/src/org/forester/sdi/SDIse.java
forester/java/src/org/forester/sdi/SDIx.java
forester/java/src/org/forester/sdi/TaxonomyAssigner.java
forester/java/src/org/forester/sdi/TestGSDI.java
forester/java/src/org/forester/sdi/Tuplet.java
forester/java/src/org/forester/sequence/BasicSequence.java
forester/java/src/org/forester/sequence/Sequence.java
forester/java/src/org/forester/surfacing/AdjactantDirectedBinaryDomainCombination.java
forester/java/src/org/forester/surfacing/AdjactantDirectedCombinableDomains.java
forester/java/src/org/forester/surfacing/BasicBinaryDomainCombination.java
forester/java/src/org/forester/surfacing/BasicCombinableDomains.java
forester/java/src/org/forester/surfacing/BasicDomain.java
forester/java/src/org/forester/surfacing/BasicDomainSimilarityCalculator.java
forester/java/src/org/forester/surfacing/BasicGenomeWideCombinableDomains.java
forester/java/src/org/forester/surfacing/BasicProtein.java
forester/java/src/org/forester/surfacing/BasicSpecies.java
forester/java/src/org/forester/surfacing/BinaryDomainCombination.java
forester/java/src/org/forester/surfacing/CombinableDomains.java
forester/java/src/org/forester/surfacing/CombinationsBasedPairwiseDomainSimilarity.java
forester/java/src/org/forester/surfacing/CombinationsBasedPairwiseDomainSimilarityCalculator.java
forester/java/src/org/forester/surfacing/CountsBasedPairwiseDomainSimilarity.java
forester/java/src/org/forester/surfacing/DirectedBinaryDomainCombination.java
forester/java/src/org/forester/surfacing/DirectedCombinableDomains.java
forester/java/src/org/forester/surfacing/Domain.java
forester/java/src/org/forester/surfacing/DomainArchitectureBasedGenomeSimilarityCalculator.java
forester/java/src/org/forester/surfacing/DomainCountsBasedPairwiseSimilarityCalculator.java
forester/java/src/org/forester/surfacing/DomainCountsDifferenceUtil.java
forester/java/src/org/forester/surfacing/DomainId.java
forester/java/src/org/forester/surfacing/DomainLengths.java
forester/java/src/org/forester/surfacing/DomainLengthsTable.java
forester/java/src/org/forester/surfacing/DomainParsimonyCalculator.java
forester/java/src/org/forester/surfacing/DomainSimilarity.java
forester/java/src/org/forester/surfacing/DomainSimilarityCalculator.java
forester/java/src/org/forester/surfacing/GenomeWideCombinableDomains.java
forester/java/src/org/forester/surfacing/MappingResults.java
forester/java/src/org/forester/surfacing/PairwiseDomainSimilarity.java
forester/java/src/org/forester/surfacing/PairwiseDomainSimilarityCalculator.java
forester/java/src/org/forester/surfacing/PairwiseGenomeComparator.java
forester/java/src/org/forester/surfacing/PrintableDomainSimilarity.java
forester/java/src/org/forester/surfacing/PrintableSpeciesSpecificDomainSimilariyData.java
forester/java/src/org/forester/surfacing/Protein.java
forester/java/src/org/forester/surfacing/ProteinCountsBasedPairwiseDomainSimilarityCalculator.java
forester/java/src/org/forester/surfacing/ProteinId.java
forester/java/src/org/forester/surfacing/SimpleDomain.java
forester/java/src/org/forester/surfacing/Species.java
forester/java/src/org/forester/surfacing/SpeciesSpecificDomainSimilariyData.java
forester/java/src/org/forester/surfacing/SurfacingConstants.java
forester/java/src/org/forester/surfacing/SurfacingUtil.java
forester/java/src/org/forester/surfacing/TestSurfacing.java
forester/java/src/org/forester/test/Test.java
forester/java/src/org/forester/tools/ConfidenceAssessor.java
forester/java/src/org/forester/tools/PhylogenyDecorator.java
forester/java/src/org/forester/tools/SupportCount.java
forester/java/src/org/forester/tools/TreeSplitMatrix.java
forester/java/src/org/forester/util/AsciiHistogram.java
forester/java/src/org/forester/util/BasicDescriptiveStatistics.java
forester/java/src/org/forester/util/BasicTable.java
forester/java/src/org/forester/util/BasicTableParser.java
forester/java/src/org/forester/util/CommandLineArguments.java
forester/java/src/org/forester/util/CommandProcessBuilder.java
forester/java/src/org/forester/util/DescriptiveStatistics.java
forester/java/src/org/forester/util/ExternalProgram.java
forester/java/src/org/forester/util/FailedConditionCheckException.java
forester/java/src/org/forester/util/ForesterConstants.java
forester/java/src/org/forester/util/ForesterUtil.java
forester/java/src/org/forester/util/GeneralTable.java
forester/java/src/org/forester/util/IllegalFormatUseException.java
forester/java/src/org/forester/util/WindowsUtils.java
forester/java/src/org/forester/ws/uniprot/UniProtTaxonomy.java
forester/java/src/org/forester/ws/uniprot/UniProtWsTools.java
forester/java/src/org/forester/ws/wabi/RestUtil.java
forester/java/src/org/forester/ws/wabi/TxSearch.java
forester/java/src/org/forester/ws/wabi/WabiTools.java

index b9e6b46..4f114a2 100644 (file)
@@ -4,7 +4,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -14,7 +14,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -43,380 +43,366 @@ import org.forester.ws.uniprot.UniProtWsTools;
 
 public final class AncestralTaxonomyInference {
 
-       private static final int MAX_CACHE_SIZE = 100000;
-       private static final int MAX_TAXONOMIES_TO_RETURN = 100;
-       private static final HashMap<String, UniProtTaxonomy> _sn_up_cache_map = new HashMap<String, UniProtTaxonomy>();
-       private static final HashMap<String, UniProtTaxonomy> _code_up_cache_map = new HashMap<String, UniProtTaxonomy>();
-       private static final HashMap<String, UniProtTaxonomy> _cn_up_cache_map = new HashMap<String, UniProtTaxonomy>();
-       private static final HashMap<String, UniProtTaxonomy> _id_up_cache_map = new HashMap<String, UniProtTaxonomy>();
+    private static final int                              MAX_CACHE_SIZE           = 100000;
+    private static final int                              MAX_TAXONOMIES_TO_RETURN = 100;
+    private static final HashMap<String, UniProtTaxonomy> _sn_up_cache_map         = new HashMap<String, UniProtTaxonomy>();
+    private static final HashMap<String, UniProtTaxonomy> _code_up_cache_map       = new HashMap<String, UniProtTaxonomy>();
+    private static final HashMap<String, UniProtTaxonomy> _cn_up_cache_map         = new HashMap<String, UniProtTaxonomy>();
+    private static final HashMap<String, UniProtTaxonomy> _id_up_cache_map         = new HashMap<String, UniProtTaxonomy>();
 
-       synchronized private static void clearCachesIfTooLarge() {
-               if (getSnTaxCacheMap().size() > MAX_CACHE_SIZE) {
-                       getSnTaxCacheMap().clear();
-               }
-               if (getCnTaxCacheMap().size() > MAX_CACHE_SIZE) {
-                       getCnTaxCacheMap().clear();
-               }
-               if (getCodeTaxCacheMap().size() > MAX_CACHE_SIZE) {
-                       getCodeTaxCacheMap().clear();
-               }
-               if (getIdTaxCacheMap().size() > MAX_CACHE_SIZE) {
-                       getIdTaxCacheMap().clear();
-               }
-       }
+    synchronized private static void clearCachesIfTooLarge() {
+        if ( getSnTaxCacheMap().size() > MAX_CACHE_SIZE ) {
+            getSnTaxCacheMap().clear();
+        }
+        if ( getCnTaxCacheMap().size() > MAX_CACHE_SIZE ) {
+            getCnTaxCacheMap().clear();
+        }
+        if ( getCodeTaxCacheMap().size() > MAX_CACHE_SIZE ) {
+            getCodeTaxCacheMap().clear();
+        }
+        if ( getIdTaxCacheMap().size() > MAX_CACHE_SIZE ) {
+            getIdTaxCacheMap().clear();
+        }
+    }
 
-       synchronized private static HashMap<String, UniProtTaxonomy> getCnTaxCacheMap() {
-               return _cn_up_cache_map;
-       }
+    synchronized private static HashMap<String, UniProtTaxonomy> getCnTaxCacheMap() {
+        return _cn_up_cache_map;
+    }
 
-       synchronized private static HashMap<String, UniProtTaxonomy> getCodeTaxCacheMap() {
-               return _code_up_cache_map;
-       }
+    synchronized private static HashMap<String, UniProtTaxonomy> getCodeTaxCacheMap() {
+        return _code_up_cache_map;
+    }
 
-       synchronized private static HashMap<String, UniProtTaxonomy> getIdTaxCacheMap() {
-               return _id_up_cache_map;
-       }
+    synchronized private static HashMap<String, UniProtTaxonomy> getIdTaxCacheMap() {
+        return _id_up_cache_map;
+    }
 
-       synchronized private static HashMap<String, UniProtTaxonomy> getSnTaxCacheMap() {
-               return _sn_up_cache_map;
-       }
+    synchronized private static HashMap<String, UniProtTaxonomy> getSnTaxCacheMap() {
+        return _sn_up_cache_map;
+    }
 
-       synchronized private static UniProtTaxonomy getTaxonomies(
-                       final HashMap<String, UniProtTaxonomy> cache, final String query,
-                       final QUERY_TYPE qt) throws IOException {
-               if (cache.containsKey(query)) {
-                       return cache.get(query).copy();
-               } else {
-                       List<UniProtTaxonomy> up_taxonomies = null;
-                       switch (qt) {
-                       case ID:
-                               up_taxonomies = getTaxonomiesFromId(query);
-                               break;
-                       case CODE:
-                               up_taxonomies = getTaxonomiesFromTaxonomyCode(query);
-                               break;
-                       case SN:
-                               up_taxonomies = getTaxonomiesFromScientificName(query);
-                               break;
-                       case CN:
-                               up_taxonomies = getTaxonomiesFromCommonName(query);
-                               break;
-                       default:
-                               throw new RuntimeException();
-                       }
-                       if ((up_taxonomies != null) && (up_taxonomies.size() == 1)) {
-                               final UniProtTaxonomy up_tax = up_taxonomies.get(0);
-                               if (!ForesterUtil.isEmpty(up_tax.getScientificName())) {
-                                       getSnTaxCacheMap().put(up_tax.getScientificName(), up_tax);
-                               }
-                               if (!ForesterUtil.isEmpty(up_tax.getCode())) {
-                                       getCodeTaxCacheMap().put(up_tax.getCode(), up_tax);
-                               }
-                               if (!ForesterUtil.isEmpty(up_tax.getCommonName())) {
-                                       getCnTaxCacheMap().put(up_tax.getCommonName(), up_tax);
-                               }
-                               if (!ForesterUtil.isEmpty(up_tax.getId())) {
-                                       getIdTaxCacheMap().put(up_tax.getId(), up_tax);
-                               }
-                               return up_tax;
-                       } else {
-                               return null;
-                       }
-               }
-       }
+    synchronized private static UniProtTaxonomy getTaxonomies( final HashMap<String, UniProtTaxonomy> cache,
+                                                               final String query,
+                                                               final QUERY_TYPE qt ) throws IOException {
+        if ( cache.containsKey( query ) ) {
+            return cache.get( query ).copy();
+        }
+        else {
+            List<UniProtTaxonomy> up_taxonomies = null;
+            switch ( qt ) {
+                case ID:
+                    up_taxonomies = getTaxonomiesFromId( query );
+                    break;
+                case CODE:
+                    up_taxonomies = getTaxonomiesFromTaxonomyCode( query );
+                    break;
+                case SN:
+                    up_taxonomies = getTaxonomiesFromScientificName( query );
+                    break;
+                case CN:
+                    up_taxonomies = getTaxonomiesFromCommonName( query );
+                    break;
+                default:
+                    throw new RuntimeException();
+            }
+            if ( ( up_taxonomies != null ) && ( up_taxonomies.size() == 1 ) ) {
+                final UniProtTaxonomy up_tax = up_taxonomies.get( 0 );
+                if ( !ForesterUtil.isEmpty( up_tax.getScientificName() ) ) {
+                    getSnTaxCacheMap().put( up_tax.getScientificName(), up_tax );
+                }
+                if ( !ForesterUtil.isEmpty( up_tax.getCode() ) ) {
+                    getCodeTaxCacheMap().put( up_tax.getCode(), up_tax );
+                }
+                if ( !ForesterUtil.isEmpty( up_tax.getCommonName() ) ) {
+                    getCnTaxCacheMap().put( up_tax.getCommonName(), up_tax );
+                }
+                if ( !ForesterUtil.isEmpty( up_tax.getId() ) ) {
+                    getIdTaxCacheMap().put( up_tax.getId(), up_tax );
+                }
+                return up_tax;
+            }
+            else {
+                return null;
+            }
+        }
+    }
 
-       synchronized private static List<UniProtTaxonomy> getTaxonomiesFromCommonName(
-                       final String query) throws IOException {
-               return UniProtWsTools.getTaxonomiesFromCommonNameStrict(query,
-                               MAX_TAXONOMIES_TO_RETURN);
-       }
+    synchronized private static List<UniProtTaxonomy> getTaxonomiesFromCommonName( final String query )
+            throws IOException {
+        return UniProtWsTools.getTaxonomiesFromCommonNameStrict( query, MAX_TAXONOMIES_TO_RETURN );
+    }
 
-       synchronized private static List<UniProtTaxonomy> getTaxonomiesFromId(
-                       final String query) throws IOException {
-               return UniProtWsTools.getTaxonomiesFromId(query,
-                               MAX_TAXONOMIES_TO_RETURN);
-       }
+    synchronized private static List<UniProtTaxonomy> getTaxonomiesFromId( final String query ) throws IOException {
+        return UniProtWsTools.getTaxonomiesFromId( query, MAX_TAXONOMIES_TO_RETURN );
+    }
 
-       synchronized private static List<UniProtTaxonomy> getTaxonomiesFromScientificName(
-                       final String query) throws IOException {
-               return UniProtWsTools.getTaxonomiesFromScientificNameStrict(query,
-                               MAX_TAXONOMIES_TO_RETURN);
-       }
+    synchronized private static List<UniProtTaxonomy> getTaxonomiesFromScientificName( final String query )
+            throws IOException {
+        return UniProtWsTools.getTaxonomiesFromScientificNameStrict( query, MAX_TAXONOMIES_TO_RETURN );
+    }
 
-       synchronized private static List<UniProtTaxonomy> getTaxonomiesFromTaxonomyCode(
-                       final String query) throws IOException {
-               return UniProtWsTools.getTaxonomiesFromTaxonomyCode(query,
-                               MAX_TAXONOMIES_TO_RETURN);
-       }
+    synchronized private static List<UniProtTaxonomy> getTaxonomiesFromTaxonomyCode( final String query )
+            throws IOException {
+        return UniProtWsTools.getTaxonomiesFromTaxonomyCode( query, MAX_TAXONOMIES_TO_RETURN );
+    }
 
-       synchronized public static SortedSet<String> inferTaxonomyFromDescendents(
-                       final Phylogeny phy) throws IOException {
-               clearCachesIfTooLarge();
-               final SortedSet<String> not_found = new TreeSet<String>();
-               for (final PhylogenyNodeIterator iter = phy.iteratorPostorder(); iter
-                               .hasNext();) {
-                       final PhylogenyNode node = iter.next();
-                       // final QUERY_TYPE qt = null;
-                       // Taxonomy tax = null;
-                       // if ( node.getNodeData().isHasTaxonomy() ) {
-                       // tax = node.getNodeData().getTaxonomy();
-                       // }
-                       // UniProtTaxonomy up_tax = null;
-                       // if ( ( tax != null )
-                       // && ( isHasAppropriateId( tax ) || !ForesterUtil.isEmpty(
-                       // tax.getScientificName() )
-                       // || !ForesterUtil.isEmpty( tax.getTaxonomyCode() ) ||
-                       // !ForesterUtil.isEmpty( tax
-                       // .getCommonName() ) ) ) {
-                       // final String query = null;
-                       // up_tax = obtainUniProtTaxonomy( tax, query, qt );
-                       // if ( up_tax == null ) {
-                       // not_found.add( query );
-                       // }
-                       // else {
-                       // updateTaxonomy( qt, node, tax, up_tax );
-                       // }
-                       // }
-                       if (!node.isExternal()) {
-                               inferTaxonomyFromDescendents(node, not_found);
-                       }
-               }
-               return not_found;
-       }
+    synchronized public static SortedSet<String> inferTaxonomyFromDescendents( final Phylogeny phy ) throws IOException {
+        clearCachesIfTooLarge();
+        final SortedSet<String> not_found = new TreeSet<String>();
+        for( final PhylogenyNodeIterator iter = phy.iteratorPostorder(); iter.hasNext(); ) {
+            final PhylogenyNode node = iter.next();
+            // final QUERY_TYPE qt = null;
+            // Taxonomy tax = null;
+            // if ( node.getNodeData().isHasTaxonomy() ) {
+            // tax = node.getNodeData().getTaxonomy();
+            // }
+            // UniProtTaxonomy up_tax = null;
+            // if ( ( tax != null )
+            // && ( isHasAppropriateId( tax ) || !ForesterUtil.isEmpty(
+            // tax.getScientificName() )
+            // || !ForesterUtil.isEmpty( tax.getTaxonomyCode() ) ||
+            // !ForesterUtil.isEmpty( tax
+            // .getCommonName() ) ) ) {
+            // final String query = null;
+            // up_tax = obtainUniProtTaxonomy( tax, query, qt );
+            // if ( up_tax == null ) {
+            // not_found.add( query );
+            // }
+            // else {
+            // updateTaxonomy( qt, node, tax, up_tax );
+            // }
+            // }
+            if ( !node.isExternal() ) {
+                inferTaxonomyFromDescendents( node, not_found );
+            }
+        }
+        return not_found;
+    }
 
-       synchronized private static void inferTaxonomyFromDescendents(
-                       final PhylogenyNode n, final SortedSet<String> not_found)
-                       throws IOException {
-               if (n.isExternal()) {
-                       throw new IllegalArgumentException(
-                                       "attempt to infer taxonomy from descendants of external node");
-               }
-               n.getNodeData().setTaxonomy(null);
-               final List<PhylogenyNode> descs = n.getDescendants();
-               final List<String[]> lineages = new ArrayList<String[]>();
-               int shortest_lin_length = Integer.MAX_VALUE;
-               for (final PhylogenyNode desc : descs) {
-                       if (desc.getNodeData().isHasTaxonomy()
-                                       && (isHasAppropriateId(desc.getNodeData().getTaxonomy())
-                                                       || !ForesterUtil.isEmpty(desc.getNodeData()
-                                                                       .getTaxonomy().getScientificName())
-                                                       || !ForesterUtil.isEmpty(desc.getNodeData()
-                                                                       .getTaxonomy().getTaxonomyCode()) || !ForesterUtil
-                                                       .isEmpty(desc.getNodeData().getTaxonomy()
-                                                                       .getCommonName()))) {
-                               final QUERY_TYPE qt = null;
-                               final String query = null;
-                               final UniProtTaxonomy up_tax = obtainUniProtTaxonomy(desc
-                                               .getNodeData().getTaxonomy(), query, qt);
-                               String[] lineage = null;
-                               if (up_tax != null) {
-                                       lineage = obtainLineagePlusOwnScientificName(up_tax);
-                               }
-                               if ((lineage == null) || (lineage.length < 1)) {
-                                       not_found.add(desc.getNodeData().getTaxonomy().asText()
-                                                       .toString());
-                                       return;
-                               }
-                               if (lineage.length < shortest_lin_length) {
-                                       shortest_lin_length = lineage.length;
-                               }
-                               lineages.add(lineage);
-                       } else {
-                               String msg = "Node(s) with no or inappropriate taxonomic information found";
-                               if (!ForesterUtil.isEmpty(desc.getName())) {
-                                       msg = "Node " + desc.getName()
-                                                       + " has no or inappropriate taxonomic information";
-                               }
-                               throw new IllegalArgumentException(msg);
-                       }
-               }
-               String last_common_lineage = null;
-               if (shortest_lin_length > 0) {
-                       I: for (int i = 0; i < shortest_lin_length; ++i) {
-                               final String lineage_0 = lineages.get(0)[i];
-                               for (int j = 1; j < lineages.size(); ++j) {
-                                       if (!lineage_0.equals(lineages.get(j)[i])) {
-                                               break I;
-                                       }
-                               }
-                               last_common_lineage = lineage_0;
-                       }
-               }
-               if (last_common_lineage == null) {
-                       return;
-               }
-               // if ( !n.getNodeData().isHasTaxonomy() ) {
-               // n.getNodeData().setTaxonomy( new Taxonomy() );
-               // }
-               final Taxonomy tax = new Taxonomy();
-               n.getNodeData().setTaxonomy(tax);
-               tax.setScientificName(last_common_lineage);
-               final UniProtTaxonomy up_tax = obtainUniProtTaxonomyFromSn(last_common_lineage);
-               if (up_tax != null) {
-                       if (!ForesterUtil.isEmpty(up_tax.getRank())) {
-                               try {
-                                       tax.setRank(up_tax.getRank().toLowerCase());
-                               } catch (final PhyloXmlDataFormatException ex) {
-                                       tax.setRank("");
-                               }
-                       }
-                       if (!ForesterUtil.isEmpty(up_tax.getId())) {
-                               tax.setIdentifier(new Identifier(up_tax.getId(), "uniprot"));
-                       }
-                       if (!ForesterUtil.isEmpty(up_tax.getCommonName())) {
-                               tax.setCommonName(up_tax.getCommonName());
-                       }
-                       if (!ForesterUtil.isEmpty(up_tax.getSynonym())
-                                       && !tax.getSynonyms().contains(up_tax.getSynonym())) {
-                               tax.getSynonyms().add(up_tax.getSynonym());
-                       }
-               }
-               for (final PhylogenyNode desc : descs) {
-                       if (!desc.isExternal() && desc.getNodeData().isHasTaxonomy()
-                                       && desc.getNodeData().getTaxonomy().isEqual(tax)) {
-                               desc.getNodeData().setTaxonomy(null);
-                       }
-               }
-       }
+    synchronized private static void inferTaxonomyFromDescendents( final PhylogenyNode n,
+                                                                   final SortedSet<String> not_found )
+            throws IOException {
+        if ( n.isExternal() ) {
+            throw new IllegalArgumentException( "attempt to infer taxonomy from descendants of external node" );
+        }
+        n.getNodeData().setTaxonomy( null );
+        final List<PhylogenyNode> descs = n.getDescendants();
+        final List<String[]> lineages = new ArrayList<String[]>();
+        int shortest_lin_length = Integer.MAX_VALUE;
+        for( final PhylogenyNode desc : descs ) {
+            if ( desc.getNodeData().isHasTaxonomy()
+                    && ( isHasAppropriateId( desc.getNodeData().getTaxonomy() )
+                            || !ForesterUtil.isEmpty( desc.getNodeData().getTaxonomy().getScientificName() )
+                            || !ForesterUtil.isEmpty( desc.getNodeData().getTaxonomy().getTaxonomyCode() ) || !ForesterUtil
+                            .isEmpty( desc.getNodeData().getTaxonomy().getCommonName() ) ) ) {
+                final QUERY_TYPE qt = null;
+                final String query = null;
+                final UniProtTaxonomy up_tax = obtainUniProtTaxonomy( desc.getNodeData().getTaxonomy(), query, qt );
+                String[] lineage = null;
+                if ( up_tax != null ) {
+                    lineage = obtainLineagePlusOwnScientificName( up_tax );
+                }
+                if ( ( lineage == null ) || ( lineage.length < 1 ) ) {
+                    not_found.add( desc.getNodeData().getTaxonomy().asText().toString() );
+                    return;
+                }
+                if ( lineage.length < shortest_lin_length ) {
+                    shortest_lin_length = lineage.length;
+                }
+                lineages.add( lineage );
+            }
+            else {
+                String msg = "Node(s) with no or inappropriate taxonomic information found";
+                if ( !ForesterUtil.isEmpty( desc.getName() ) ) {
+                    msg = "Node " + desc.getName() + " has no or inappropriate taxonomic information";
+                }
+                throw new IllegalArgumentException( msg );
+            }
+        }
+        String last_common_lineage = null;
+        if ( shortest_lin_length > 0 ) {
+            I: for( int i = 0; i < shortest_lin_length; ++i ) {
+                final String lineage_0 = lineages.get( 0 )[ i ];
+                for( int j = 1; j < lineages.size(); ++j ) {
+                    if ( !lineage_0.equals( lineages.get( j )[ i ] ) ) {
+                        break I;
+                    }
+                }
+                last_common_lineage = lineage_0;
+            }
+        }
+        if ( last_common_lineage == null ) {
+            return;
+        }
+        // if ( !n.getNodeData().isHasTaxonomy() ) {
+        // n.getNodeData().setTaxonomy( new Taxonomy() );
+        // }
+        final Taxonomy tax = new Taxonomy();
+        n.getNodeData().setTaxonomy( tax );
+        tax.setScientificName( last_common_lineage );
+        final UniProtTaxonomy up_tax = obtainUniProtTaxonomyFromSn( last_common_lineage );
+        if ( up_tax != null ) {
+            if ( !ForesterUtil.isEmpty( up_tax.getRank() ) ) {
+                try {
+                    tax.setRank( up_tax.getRank().toLowerCase() );
+                }
+                catch ( final PhyloXmlDataFormatException ex ) {
+                    tax.setRank( "" );
+                }
+            }
+            if ( !ForesterUtil.isEmpty( up_tax.getId() ) ) {
+                tax.setIdentifier( new Identifier( up_tax.getId(), "uniprot" ) );
+            }
+            if ( !ForesterUtil.isEmpty( up_tax.getCommonName() ) ) {
+                tax.setCommonName( up_tax.getCommonName() );
+            }
+            if ( !ForesterUtil.isEmpty( up_tax.getSynonym() ) && !tax.getSynonyms().contains( up_tax.getSynonym() ) ) {
+                tax.getSynonyms().add( up_tax.getSynonym() );
+            }
+        }
+        for( final PhylogenyNode desc : descs ) {
+            if ( !desc.isExternal() && desc.getNodeData().isHasTaxonomy()
+                    && desc.getNodeData().getTaxonomy().isEqual( tax ) ) {
+                desc.getNodeData().setTaxonomy( null );
+            }
+        }
+    }
 
-       synchronized private static boolean isHasAppropriateId(final Taxonomy tax) {
-               return ((tax.getIdentifier() != null) && (!ForesterUtil.isEmpty(tax
-                               .getIdentifier().getValue()) && (tax.getIdentifier()
-                               .getProvider().equalsIgnoreCase("ncbi")
-                               || tax.getIdentifier().getProvider()
-                                               .equalsIgnoreCase("uniprot") || tax.getIdentifier()
-                               .getProvider().equalsIgnoreCase("uniprotkb"))));
-       }
+    synchronized private static boolean isHasAppropriateId( final Taxonomy tax ) {
+        return ( ( tax.getIdentifier() != null ) && ( !ForesterUtil.isEmpty( tax.getIdentifier().getValue() ) && ( tax
+                .getIdentifier().getProvider().equalsIgnoreCase( "ncbi" )
+                || tax.getIdentifier().getProvider().equalsIgnoreCase( "uniprot" ) || tax.getIdentifier().getProvider()
+                .equalsIgnoreCase( "uniprotkb" ) ) ) );
+    }
 
-       synchronized public static SortedSet<String> obtainDetailedTaxonomicInformation(
-                       final Phylogeny phy) throws IOException {
-               clearCachesIfTooLarge();
-               final SortedSet<String> not_found = new TreeSet<String>();
-               for (final PhylogenyNodeIterator iter = phy.iteratorPostorder(); iter
-                               .hasNext();) {
-                       final PhylogenyNode node = iter.next();
-                       final QUERY_TYPE qt = null;
-                       Taxonomy tax = null;
-                       if (node.getNodeData().isHasTaxonomy()) {
-                               tax = node.getNodeData().getTaxonomy();
-                       } else if (node.isExternal()) {
-                               if (!ForesterUtil.isEmpty(node.getName())) {
-                                       not_found.add(node.getName());
-                               } else {
-                                       not_found.add(node.toString());
-                               }
-                       }
-                       UniProtTaxonomy up_tax = null;
-                       if ((tax != null)
-                                       && (isHasAppropriateId(tax)
-                                                       || !ForesterUtil.isEmpty(tax.getScientificName())
-                                                       || !ForesterUtil.isEmpty(tax.getTaxonomyCode()) || !ForesterUtil
-                                                       .isEmpty(tax.getCommonName()))) {
-                               up_tax = obtainUniProtTaxonomy(tax, null, qt);
-                               if (up_tax != null) {
-                                       updateTaxonomy(qt, node, tax, up_tax);
-                               } else {
-                                       not_found.add(tax.toString());
-                               }
-                       }
-               }
-               return not_found;
-       }
+    synchronized public static SortedSet<String> obtainDetailedTaxonomicInformation( final Phylogeny phy )
+            throws IOException {
+        clearCachesIfTooLarge();
+        final SortedSet<String> not_found = new TreeSet<String>();
+        for( final PhylogenyNodeIterator iter = phy.iteratorPostorder(); iter.hasNext(); ) {
+            final PhylogenyNode node = iter.next();
+            final QUERY_TYPE qt = null;
+            Taxonomy tax = null;
+            if ( node.getNodeData().isHasTaxonomy() ) {
+                tax = node.getNodeData().getTaxonomy();
+            }
+            else if ( node.isExternal() ) {
+                if ( !ForesterUtil.isEmpty( node.getName() ) ) {
+                    not_found.add( node.getName() );
+                }
+                else {
+                    not_found.add( node.toString() );
+                }
+            }
+            UniProtTaxonomy up_tax = null;
+            if ( ( tax != null )
+                    && ( isHasAppropriateId( tax ) || !ForesterUtil.isEmpty( tax.getScientificName() )
+                            || !ForesterUtil.isEmpty( tax.getTaxonomyCode() ) || !ForesterUtil.isEmpty( tax
+                            .getCommonName() ) ) ) {
+                up_tax = obtainUniProtTaxonomy( tax, null, qt );
+                if ( up_tax != null ) {
+                    updateTaxonomy( qt, node, tax, up_tax );
+                }
+                else {
+                    not_found.add( tax.toString() );
+                }
+            }
+        }
+        return not_found;
+    }
 
-       synchronized private static String[] obtainLineagePlusOwnScientificName(
-                       final UniProtTaxonomy up_tax) {
-               final String[] lineage = up_tax.getLineage();
-               final String[] lin_plus_self = new String[lineage.length + 1];
-               for (int i = 0; i < lineage.length; ++i) {
-                       lin_plus_self[i] = lineage[i];
-               }
-               lin_plus_self[lineage.length] = up_tax.getScientificName();
-               return lin_plus_self;
-       }
+    synchronized private static String[] obtainLineagePlusOwnScientificName( final UniProtTaxonomy up_tax ) {
+        final String[] lineage = up_tax.getLineage();
+        final String[] lin_plus_self = new String[ lineage.length + 1 ];
+        for( int i = 0; i < lineage.length; ++i ) {
+            lin_plus_self[ i ] = lineage[ i ];
+        }
+        lin_plus_self[ lineage.length ] = up_tax.getScientificName();
+        return lin_plus_self;
+    }
 
-       synchronized private static UniProtTaxonomy obtainUniProtTaxonomy(
-                       final Taxonomy tax, String query, QUERY_TYPE qt) throws IOException {
-               if (isHasAppropriateId(tax)) {
-                       query = tax.getIdentifier().getValue();
-                       qt = QUERY_TYPE.ID;
-                       return getTaxonomies(getIdTaxCacheMap(), query, qt);
-               } else if (!ForesterUtil.isEmpty(tax.getScientificName())) {
-                       query = tax.getScientificName();
-                       qt = QUERY_TYPE.SN;
-                       return getTaxonomies(getSnTaxCacheMap(), query, qt);
-               } else if (!ForesterUtil.isEmpty(tax.getTaxonomyCode())) {
-                       query = tax.getTaxonomyCode();
-                       qt = QUERY_TYPE.CODE;
-                       return getTaxonomies(getCodeTaxCacheMap(), query, qt);
-               } else {
-                       query = tax.getCommonName();
-                       qt = QUERY_TYPE.CN;
-                       return getTaxonomies(getCnTaxCacheMap(), query, qt);
-               }
-       }
+    synchronized private static UniProtTaxonomy obtainUniProtTaxonomy( final Taxonomy tax, String query, QUERY_TYPE qt )
+            throws IOException {
+        if ( isHasAppropriateId( tax ) ) {
+            query = tax.getIdentifier().getValue();
+            qt = QUERY_TYPE.ID;
+            return getTaxonomies( getIdTaxCacheMap(), query, qt );
+        }
+        else if ( !ForesterUtil.isEmpty( tax.getScientificName() ) ) {
+            query = tax.getScientificName();
+            qt = QUERY_TYPE.SN;
+            return getTaxonomies( getSnTaxCacheMap(), query, qt );
+        }
+        else if ( !ForesterUtil.isEmpty( tax.getTaxonomyCode() ) ) {
+            query = tax.getTaxonomyCode();
+            qt = QUERY_TYPE.CODE;
+            return getTaxonomies( getCodeTaxCacheMap(), query, qt );
+        }
+        else {
+            query = tax.getCommonName();
+            qt = QUERY_TYPE.CN;
+            return getTaxonomies( getCnTaxCacheMap(), query, qt );
+        }
+    }
 
-       synchronized private static UniProtTaxonomy obtainUniProtTaxonomyFromSn(
-                       final String sn) throws IOException {
-               UniProtTaxonomy up_tax = null;
-               if (getSnTaxCacheMap().containsKey(sn)) {
-                       up_tax = getSnTaxCacheMap().get(sn).copy();
-               } else {
-                       final List<UniProtTaxonomy> up_taxonomies = getTaxonomiesFromScientificName(sn);
-                       if ((up_taxonomies != null) && (up_taxonomies.size() == 1)) {
-                               up_tax = up_taxonomies.get(0);
-                               getSnTaxCacheMap().put(sn, up_tax);
-                               if (!ForesterUtil.isEmpty(up_tax.getCode())) {
-                                       getCodeTaxCacheMap().put(up_tax.getCode(), up_tax);
-                               }
-                               if (!ForesterUtil.isEmpty(up_tax.getCommonName())) {
-                                       getCnTaxCacheMap().put(up_tax.getCommonName(), up_tax);
-                               }
-                               if (!ForesterUtil.isEmpty(up_tax.getId())) {
-                                       getIdTaxCacheMap().put(up_tax.getId(), up_tax);
-                               }
-                       }
-               }
-               return up_tax;
-       }
+    synchronized private static UniProtTaxonomy obtainUniProtTaxonomyFromSn( final String sn ) throws IOException {
+        UniProtTaxonomy up_tax = null;
+        if ( getSnTaxCacheMap().containsKey( sn ) ) {
+            up_tax = getSnTaxCacheMap().get( sn ).copy();
+        }
+        else {
+            final List<UniProtTaxonomy> up_taxonomies = getTaxonomiesFromScientificName( sn );
+            if ( ( up_taxonomies != null ) && ( up_taxonomies.size() == 1 ) ) {
+                up_tax = up_taxonomies.get( 0 );
+                getSnTaxCacheMap().put( sn, up_tax );
+                if ( !ForesterUtil.isEmpty( up_tax.getCode() ) ) {
+                    getCodeTaxCacheMap().put( up_tax.getCode(), up_tax );
+                }
+                if ( !ForesterUtil.isEmpty( up_tax.getCommonName() ) ) {
+                    getCnTaxCacheMap().put( up_tax.getCommonName(), up_tax );
+                }
+                if ( !ForesterUtil.isEmpty( up_tax.getId() ) ) {
+                    getIdTaxCacheMap().put( up_tax.getId(), up_tax );
+                }
+            }
+        }
+        return up_tax;
+    }
 
-       synchronized private static void updateTaxonomy(final QUERY_TYPE qt,
-                       final PhylogenyNode node, final Taxonomy tax,
-                       final UniProtTaxonomy up_tax) {
-               if ((qt != QUERY_TYPE.SN)
-                               && !ForesterUtil.isEmpty(up_tax.getScientificName())
-                               && ForesterUtil.isEmpty(tax.getScientificName())) {
-                       tax.setScientificName(up_tax.getScientificName());
-               }
-               if (node.isExternal()
-                               && ((qt != QUERY_TYPE.CODE)
-                                               && !ForesterUtil.isEmpty(up_tax.getCode()) && ForesterUtil
-                                               .isEmpty(tax.getTaxonomyCode()))) {
-                       tax.setTaxonomyCode(up_tax.getCode());
-               }
-               if ((qt != QUERY_TYPE.CN)
-                               && !ForesterUtil.isEmpty(up_tax.getCommonName())
-                               && ForesterUtil.isEmpty(tax.getCommonName())) {
-                       tax.setCommonName(up_tax.getCommonName());
-               }
-               if (!ForesterUtil.isEmpty(up_tax.getSynonym())
-                               && !tax.getSynonyms().contains(up_tax.getSynonym())) {
-                       tax.getSynonyms().add(up_tax.getSynonym());
-               }
-               if (!ForesterUtil.isEmpty(up_tax.getRank())
-                               && ForesterUtil.isEmpty(tax.getRank())) {
-                       try {
-                               tax.setRank(up_tax.getRank().toLowerCase());
-                       } catch (final PhyloXmlDataFormatException ex) {
-                               tax.setRank("");
-                       }
-               }
-               if ((qt != QUERY_TYPE.ID) && !ForesterUtil.isEmpty(up_tax.getId())
-                               && (tax.getIdentifier() == null)) {
-                       tax.setIdentifier(new Identifier(up_tax.getId(), "uniprot"));
-               }
-       }
+    synchronized private static void updateTaxonomy( final QUERY_TYPE qt,
+                                                     final PhylogenyNode node,
+                                                     final Taxonomy tax,
+                                                     final UniProtTaxonomy up_tax ) {
+        if ( ( qt != QUERY_TYPE.SN ) && !ForesterUtil.isEmpty( up_tax.getScientificName() )
+                && ForesterUtil.isEmpty( tax.getScientificName() ) ) {
+            tax.setScientificName( up_tax.getScientificName() );
+        }
+        if ( node.isExternal()
+                && ( ( qt != QUERY_TYPE.CODE ) && !ForesterUtil.isEmpty( up_tax.getCode() ) && ForesterUtil
+                        .isEmpty( tax.getTaxonomyCode() ) ) ) {
+            tax.setTaxonomyCode( up_tax.getCode() );
+        }
+        if ( ( qt != QUERY_TYPE.CN ) && !ForesterUtil.isEmpty( up_tax.getCommonName() )
+                && ForesterUtil.isEmpty( tax.getCommonName() ) ) {
+            tax.setCommonName( up_tax.getCommonName() );
+        }
+        if ( !ForesterUtil.isEmpty( up_tax.getSynonym() ) && !tax.getSynonyms().contains( up_tax.getSynonym() ) ) {
+            tax.getSynonyms().add( up_tax.getSynonym() );
+        }
+        if ( !ForesterUtil.isEmpty( up_tax.getRank() ) && ForesterUtil.isEmpty( tax.getRank() ) ) {
+            try {
+                tax.setRank( up_tax.getRank().toLowerCase() );
+            }
+            catch ( final PhyloXmlDataFormatException ex ) {
+                tax.setRank( "" );
+            }
+        }
+        if ( ( qt != QUERY_TYPE.ID ) && !ForesterUtil.isEmpty( up_tax.getId() ) && ( tax.getIdentifier() == null ) ) {
+            tax.setIdentifier( new Identifier( up_tax.getId(), "uniprot" ) );
+        }
+    }
 
-       private enum QUERY_TYPE {
-               CODE, SN, CN, ID;
-       }
+    private enum QUERY_TYPE {
+        CODE, SN, CN, ID;
+    }
 }
index efccace..dbc4d50 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -148,8 +148,9 @@ public class confadd {
             targets = factory.create( target_file, ForesterUtil.createParserDependingOnFileType( target_file, true ) );
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( PRG_NAME, "failed to read target phylogenies from [" + target_file + "]: "
-                    + e.getLocalizedMessage() );
+            ForesterUtil.fatalError( PRG_NAME,
+                                     "failed to read target phylogenies from [" + target_file + "]: "
+                                             + e.getLocalizedMessage() );
         }
         int counter = 0;
         for( final Phylogeny target : targets ) {
@@ -168,8 +169,8 @@ public class confadd {
             ForesterUtil.programMessage( PRG_NAME, "read in a total of " + targets.length + " targets" );
         }
         try {
-            evaluators = factory.create( evaluators_file, ForesterUtil
-                    .createParserDependingOnFileType( evaluators_file, true ) );
+            evaluators = factory.create( evaluators_file,
+                                         ForesterUtil.createParserDependingOnFileType( evaluators_file, true ) );
         }
         catch ( final IOException e ) {
             ForesterUtil.fatalError( PRG_NAME, "failed to read evaluator topologies from [" + evaluators_file + "]: "
index 67dfc1b..e094f69 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -108,8 +108,8 @@ public class count_support {
             p = factory.create( phylogeny_infile, pp )[ 0 ];
         }
         catch ( final Exception e ) {
-            ForesterUtil.fatalError( count_support.PRG_NAME, "Could not read \"" + phylogeny_infile + "\" ["
-                    + e.getMessage() + "]" );
+            ForesterUtil.fatalError( count_support.PRG_NAME,
+                                     "Could not read \"" + phylogeny_infile + "\" [" + e.getMessage() + "]" );
         }
         try {
             final PhylogenyFactory factory = ParserBasedPhylogenyFactory.getInstance();
@@ -117,8 +117,8 @@ public class count_support {
             ev = factory.create( evaluators_infile, pp );
         }
         catch ( final Exception e ) {
-            ForesterUtil.fatalError( count_support.PRG_NAME, "Could not read \"" + evaluators_infile + "\" ["
-                    + e.getMessage() + "]" );
+            ForesterUtil.fatalError( count_support.PRG_NAME,
+                                     "Could not read \"" + evaluators_infile + "\" [" + e.getMessage() + "]" );
         }
         boolean strip = false;
         if ( cla.isOptionSet( "s" ) ) {
@@ -187,8 +187,9 @@ public class count_support {
                 else {
                     System.out.println( "Writing " + ev.length + " evaluator phylogenies to :" + evaluators_outfile );
                     if ( count_support.WRITE_EVALUATORS_AS_NHX ) {
-                        w.toNewHampshireX( Arrays.asList( ev ), evaluators_outfile, ";"
-                                + ForesterUtil.getLineSeparator() );
+                        w.toNewHampshireX( Arrays.asList( ev ),
+                                           evaluators_outfile,
+                                           ";" + ForesterUtil.getLineSeparator() );
                     }
                     else {
                         w.toNewHampshire( Arrays.asList( ev ), true, branch_lengths_in_ev_out, evaluators_outfile, ";"
index c1a2786..cec430b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -305,8 +305,8 @@ public final class decorator {
                 mapping_table = BasicTableParser.parse( mapping_infile, separator, decorator.USE_FIRST_SEPARATOR_ONLY );
             }
             catch ( final Exception e ) {
-                ForesterUtil.fatalError( decorator.PRG_NAME, "failed to read [" + mapping_infile + "] ["
-                        + e.getMessage() + "]" );
+                ForesterUtil.fatalError( decorator.PRG_NAME,
+                                         "failed to read [" + mapping_infile + "] [" + e.getMessage() + "]" );
             }
             if ( ( key_column < 0 ) || ( key_column >= mapping_table.getNumberOfColumns() ) ) {
                 ForesterUtil.fatalError( decorator.PRG_NAME, "illegal value for key column" );
@@ -343,8 +343,8 @@ public final class decorator {
                     table = PhylogenyDecorator.parseMappingTable( mapping_infile );
                 }
                 catch ( final IOException e ) {
-                    ForesterUtil.fatalError( decorator.PRG_NAME, "failed to read \"" + mapping_infile + "\" ["
-                            + e.getMessage() + "]" );
+                    ForesterUtil.fatalError( decorator.PRG_NAME,
+                                             "failed to read \"" + mapping_infile + "\" [" + e.getMessage() + "]" );
                 }
                 PhylogenyDecorator.decorate( phylogenies,
                                              table,
index 8a8d328..87d9918 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 1a6e00f..3cdceb7 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2009 Christian M. Zmasek
 // Copyright (C) 2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index e7b8b96..32acbc8 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 767edca..7ef1d56 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 31a9b26..17281b7 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d46d18f..0cb6577 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 164a170..02e26fb 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2009 Christian M. Zmasek
 // Copyright (C) 2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 8d95d86..194def2 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2009 Christian M. Zmasek
 // Copyright (C) 2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 1d6ab2f..69793ef 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 2a4ec9c..24da6d0 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9822e1f..d2c0a5c 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -47,29 +47,31 @@ import org.forester.util.ForesterUtil.PhylogenyNodeField;
 
 public class phyloxml_converter {
 
-    final static private String  HELP_OPTION_1                    = "help";
-    final static private String  HELP_OPTION_2                    = "h";
-    final static private String  FIELD_OPTION                     = "f";
-    final static private String  FIELD_CLADE_NAME                 = "nn";
-    final static private String  FIELD_TAXONOMY_CODE              = "tc";
-    final static private String  FIELD_TAXONOMY_SCI_NAME          = "sn";
-    final static private String  FIELD_TAXONOMY_COMM_NAME         = "cn";
-    final static private String  FIELD_SEQUENCE_GENE_NAME         = "gn";
-    final static private String  FIELD_SEQUENCE_SYMBOL            = "sy";
-    final static private String  FIELD_DUMMY                      = "dummy";
-    final static private String  INTERNAL_NAMES_ARE_BOOT_SUPPPORT = "i";
-    final static private String  MIDPOINT_REROOT                  = "m";
-    final static private String  EXTRACT_TAXONOMY                 = "xt";
-    final static private String  EXTRACT_TAXONOMY_PF              = "xp";
-    final static private String  ORDER_SUBTREES                   = "o";
-    final static private String  NO_TREE_LEVEL_INDENDATION        = "ni";
-    final static private String  REPLACE_UNDER_SCORES             = "ru";
-    final static private String  PRG_NAME                         = "phyloxml_converter";
-    final static private String  PRG_VERSION                      = "1.21";
-    final static private String  PRG_DATE                         = "2010.10.02";
-    final static private String  E_MAIL                           = "czmasek@burnham.org";
-    final static private String  WWW                              = "www.phylosoft.org/forester/";
-    final static private boolean SPECIAL                          = false;
+    final static private String  HELP_OPTION_1                     = "help";
+    final static private String  HELP_OPTION_2                     = "h";
+    final static private String  FIELD_OPTION                      = "f";
+    final static private String  FIELD_CLADE_NAME                  = "nn";
+    final static private String  FIELD_TAXONOMY_CODE               = "tc";
+    final static private String  FIELD_TAXONOMY_SCI_NAME           = "sn";
+    final static private String  FIELD_TAXONOMY_COMM_NAME          = "cn";
+    final static private String  FIELD_SEQUENCE_GENE_NAME          = "gn";
+    final static private String  FIELD_SEQUENCE_SYMBOL             = "sy";
+    final static private String  FIELD_UNIPROT_TAXONOMY_ID_SPLIT_1 = "i1";
+    final static private String  FIELD_UNIPROT_TAXONOMY_ID_SPLIT_2 = "i2";
+    final static private String  FIELD_DUMMY                       = "dummy";
+    final static private String  INTERNAL_NAMES_ARE_BOOT_SUPPPORT  = "i";
+    final static private String  MIDPOINT_REROOT                   = "m";
+    final static private String  EXTRACT_TAXONOMY                  = "xt";
+    final static private String  EXTRACT_TAXONOMY_PF               = "xp";
+    final static private String  ORDER_SUBTREES                    = "o";
+    final static private String  NO_TREE_LEVEL_INDENDATION         = "ni";
+    final static private String  REPLACE_UNDER_SCORES              = "ru";
+    final static private String  PRG_NAME                          = "phyloxml_converter";
+    final static private String  PRG_VERSION                       = "1.30";
+    final static private String  PRG_DATE                          = "2011.03.01";
+    final static private String  E_MAIL                            = "phylosoft@gmail.com";
+    final static private String  WWW                               = "www.phylosoft.org/forester/";
+    final static private boolean SPECIAL                           = false;
 
     public static void main( final String args[] ) {
         ForesterUtil.printProgramInformation( PRG_NAME, PRG_VERSION, PRG_DATE, E_MAIL, WWW );
@@ -142,6 +144,12 @@ public class phyloxml_converter {
         else if ( field_option_value.equals( FIELD_SEQUENCE_SYMBOL ) ) {
             field = PhylogenyNodeField.SEQUENCE_SYMBOL;
         }
+        else if ( field_option_value.equals( FIELD_UNIPROT_TAXONOMY_ID_SPLIT_1 ) ) {
+            field = PhylogenyNodeField.TAXONOMY_ID_UNIPROT_1;
+        }
+        else if ( field_option_value.equals( FIELD_UNIPROT_TAXONOMY_ID_SPLIT_2 ) ) {
+            field = PhylogenyNodeField.TAXONOMY_ID_UNIPROT_2;
+        }
         else if ( field_option_value.equals( FIELD_DUMMY ) ) {
         }
         else {
@@ -353,6 +361,14 @@ public class phyloxml_converter {
         System.out.println( "   " + FIELD_TAXONOMY_COMM_NAME + ": transfer name to taxonomy common name" );
         System.out.println( "   " + FIELD_SEQUENCE_GENE_NAME + ": transfer name to sequence name" );
         System.out.println( "   " + FIELD_SEQUENCE_SYMBOL + ": transfer name to sequence symbol" );
+        System.out
+                .println( "   "
+                        + FIELD_UNIPROT_TAXONOMY_ID_SPLIT_1
+                        + ": transfer/split name to taxonomy uniprot identifier\n       (split at underscore if \"id_name\" pattern, e.g. \"817_SusD\")" );
+        System.out
+                .println( "   "
+                        + FIELD_UNIPROT_TAXONOMY_ID_SPLIT_2
+                        + ": transfer/split name to taxonomy uniprot identifier\n       (split at underscore if \"name_id\" pattern, e.g. \"SusD_817\")" );
         System.out.println();
         System.out.println( " options: " );
         System.out.println( " -" + INTERNAL_NAMES_ARE_BOOT_SUPPPORT
index 734239b..3d31929 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 530a0fe..b45d132 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b4902b1..88e3444 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 08d94fb..47e493f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -130,16 +130,18 @@ public final class sdi {
             species_tree = factory.create( species_tree_file, new PhyloXmlParser() )[ 0 ];
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( sdi.PRG_NAME, "Failed to read species tree from \"" + gene_tree_file + "\" ["
-                    + e.getMessage() + "]" );
+            ForesterUtil.fatalError( sdi.PRG_NAME,
+                                     "Failed to read species tree from \"" + gene_tree_file + "\" [" + e.getMessage()
+                                             + "]" );
         }
         try {
             final PhylogenyFactory factory = ParserBasedPhylogenyFactory.getInstance();
             gene_tree = factory.create( gene_tree_file, new PhyloXmlParser() )[ 0 ];
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( sdi.PRG_NAME, "Failed to read gene tree from \"" + gene_tree_file + "\" ["
-                    + e.getMessage() + "]" );
+            ForesterUtil.fatalError( sdi.PRG_NAME,
+                                     "Failed to read gene tree from \"" + gene_tree_file + "\" [" + e.getMessage()
+                                             + "]" );
         }
         gene_tree.setRooted( true );
         species_tree.setRooted( true );
index fddb6e4..bc91edb 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 258e0f4..0b2475b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -115,8 +115,9 @@ public class sdi_r {
             species_tree = factory.create( species_tree_file, pp )[ 0 ];
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( PRG_NAME, "failed to read species tree [" + species_tree_file + "]: "
-                    + e.getLocalizedMessage() );
+            ForesterUtil.fatalError( PRG_NAME,
+                                     "failed to read species tree [" + species_tree_file + "]: "
+                                             + e.getLocalizedMessage() );
         }
         if ( !species_tree.isRooted() ) {
             ForesterUtil.fatalError( PRG_NAME, "species tree [" + species_tree_file + "] is not rooted" );
@@ -126,8 +127,8 @@ public class sdi_r {
             gene_trees = factory.create( gene_tree_file, pp );
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( PRG_NAME, "failed to read gene trees [" + gene_tree_file + "]: "
-                    + e.getLocalizedMessage() );
+            ForesterUtil.fatalError( PRG_NAME,
+                                     "failed to read gene trees [" + gene_tree_file + "]: " + e.getLocalizedMessage() );
         }
         // Removes from gene_tree all species not found in species_tree.
         int gene_tree_counter = 0;
@@ -197,8 +198,9 @@ public class sdi_r {
                         + ForesterUtil.FORMATTER_06.format( sdiunrooted.getMinimalTreeHeight() ) );
                 ForesterUtil.programMessage( PRG_NAME, "Minimal difference in subtree heights: "
                         + ForesterUtil.FORMATTER_06.format( sdiunrooted.getMinimalDiffInSubTreeHeights() ) );
-                ForesterUtil.programMessage( PRG_NAME, "Duplications in midpoint rooted tree : "
-                        + sdiunrooted.getMinimalDuplications() );
+                ForesterUtil.programMessage( PRG_NAME,
+                                             "Duplications in midpoint rooted tree : "
+                                                     + sdiunrooted.getMinimalDuplications() );
             }
             else {
                 ForesterUtil.programMessage( PRG_NAME, "No (re) rooting was performed." );
@@ -223,8 +225,8 @@ public class sdi_r {
             w.toPhyloXML( outfile, all_result_trees, 0, ForesterUtil.LINE_SEPARATOR );
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( PRG_NAME, "failure to write output to [" + outfile + "]: "
-                    + e.getLocalizedMessage() );
+            ForesterUtil.fatalError( PRG_NAME,
+                                     "failure to write output to [" + outfile + "]: " + e.getLocalizedMessage() );
         }
         ForesterUtil.programMessage( PRG_NAME, "Wrote: " + outfile );
         ForesterUtil.programMessage( PRG_NAME, "OK." );
index a14d459..f8304dd 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -42,11 +42,11 @@ import org.forester.util.ForesterUtil;
 
 public class sdix {
 
-    final static private String HELP_OPTION_1   = "help";
-    final static private String HELP_OPTION_2   = "h";
-    final static private String PRG_NAME        = "sdix";
-    final static private String PRG_VERSION     = "0.001 alpha";
-    final static private String PRG_DATE        = "2009.10.14";
+    final static private String HELP_OPTION_1 = "help";
+    final static private String HELP_OPTION_2 = "h";
+    final static private String PRG_NAME      = "sdix";
+    final static private String PRG_VERSION   = "0.001 alpha";
+    final static private String PRG_DATE      = "2009.10.14";
 
     public static void main( final String args[] ) {
         ForesterUtil.printProgramInformation( PRG_NAME, PRG_VERSION, PRG_DATE );
@@ -114,8 +114,9 @@ public class sdix {
             species_trees = factory.create( species_trees_file, new PhyloXmlParser() );
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( PRG_NAME, "failed to read species trees from [" + species_trees_file + "] ["
-                    + e.getMessage() + "]" );
+            ForesterUtil.fatalError( PRG_NAME,
+                                     "failed to read species trees from [" + species_trees_file + "] ["
+                                             + e.getMessage() + "]" );
         }
         if ( ( species_trees == null ) || ( species_trees.length < 1 ) ) {
             ForesterUtil.fatalError( PRG_NAME, "failed to read species trees from [" + species_trees_file + "]" );
@@ -124,6 +125,7 @@ public class sdix {
                 + species_trees_file + "]" );
         final FilenameFilter filter = new FilenameFilter() {
 
+            @Override
             public boolean accept( final File dir, final String name ) {
                 return ( !name.startsWith( "." ) && !name.startsWith( "00_" ) && name.endsWith( ".xml" ) );
             }
index 399f9f2..3f713dc 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 308878f..7af9ff8 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 7e26be7..4235048 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 12e0a41..f6e2aed 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -162,8 +162,8 @@ public final class support_transfer {
                     final List<String> ext_children_from = node_from.getAllExternalDescendantsNames();
                     if ( ( ext_children_from.size() == ext_children_to.size() )
                             && ext_children_from.containsAll( ext_children_to ) ) {
-                        PhylogenyMethods.setBootstrapConfidence( node_to, PhylogenyMethods
-                                .getConfidenceValue( node_from ) );
+                        PhylogenyMethods.setBootstrapConfidence( node_to,
+                                                                 PhylogenyMethods.getConfidenceValue( node_from ) );
                         continue to;
                     }
                 }
index 297e16f..a60d22f 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -101,8 +101,9 @@ public class surf_paup {
             phylogenies = factory.create( surfacing_nexus_outfile, phylogeny_parser );
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( PRG_NAME, "problem with parsing phylogeny [" + surfacing_nexus_outfile + "]: "
-                    + e.getMessage() );
+            ForesterUtil.fatalError( PRG_NAME,
+                                     "problem with parsing phylogeny [" + surfacing_nexus_outfile + "]: "
+                                             + e.getMessage() );
             e.printStackTrace();
         }
         if ( phylogenies.length != 1 ) {
@@ -121,11 +122,12 @@ public class surf_paup {
             matrix = paup_log_parser.parse();
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( PRG_NAME, "failed to parse matrix from  [" + paup_log_file + "]: "
-                    + e.getMessage() );
+            ForesterUtil.fatalError( PRG_NAME,
+                                     "failed to parse matrix from  [" + paup_log_file + "]: " + e.getMessage() );
         }
-        ForesterUtil.programMessage( PRG_NAME, "read in character state matrix of size "
-                + matrix.getNumberOfIdentifiers() + "x" + matrix.getNumberOfCharacters() );
+        ForesterUtil.programMessage( PRG_NAME,
+                                     "read in character state matrix of size " + matrix.getNumberOfIdentifiers() + "x"
+                                             + matrix.getNumberOfCharacters() );
         final DomainParsimonyCalculator domain_parsimony = DomainParsimonyCalculator.createInstance( phylogeny );
         domain_parsimony.executeOnGivenBinaryStatesMatrix( matrix, labels );
         final String sep = ForesterUtil.LINE_SEPARATOR + "###################" + ForesterUtil.LINE_SEPARATOR;
index 4f1073c..580eea4 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -71,21 +71,21 @@ import org.forester.surfacing.DomainId;
 import org.forester.surfacing.DomainLengthsTable;
 import org.forester.surfacing.DomainParsimonyCalculator;
 import org.forester.surfacing.DomainSimilarity;
+import org.forester.surfacing.DomainSimilarity.DomainSimilarityScoring;
+import org.forester.surfacing.DomainSimilarity.DomainSimilaritySortField;
 import org.forester.surfacing.DomainSimilarityCalculator;
+import org.forester.surfacing.DomainSimilarityCalculator.Detailedness;
 import org.forester.surfacing.GenomeWideCombinableDomains;
+import org.forester.surfacing.GenomeWideCombinableDomains.GenomeWideCombinableDomainsSortOrder;
 import org.forester.surfacing.MappingResults;
 import org.forester.surfacing.PairwiseDomainSimilarityCalculator;
 import org.forester.surfacing.PairwiseGenomeComparator;
 import org.forester.surfacing.PrintableDomainSimilarity;
+import org.forester.surfacing.PrintableDomainSimilarity.PRINT_OPTION;
 import org.forester.surfacing.Protein;
 import org.forester.surfacing.ProteinCountsBasedPairwiseDomainSimilarityCalculator;
 import org.forester.surfacing.Species;
 import org.forester.surfacing.SurfacingUtil;
-import org.forester.surfacing.DomainSimilarity.DomainSimilarityScoring;
-import org.forester.surfacing.DomainSimilarity.DomainSimilaritySortField;
-import org.forester.surfacing.DomainSimilarityCalculator.Detailedness;
-import org.forester.surfacing.GenomeWideCombinableDomains.GenomeWideCombinableDomainsSortOrder;
-import org.forester.surfacing.PrintableDomainSimilarity.PRINT_OPTION;
 import org.forester.util.BasicTable;
 import org.forester.util.BasicTableParser;
 import org.forester.util.CommandLineArguments;
@@ -522,9 +522,11 @@ public class surfacing {
                 ForesterUtil.fatalError( surfacing.PRG_NAME, "input tree [" + intree_file + "] is not rooted" );
             }
             if ( intree.getNumberOfExternalNodes() < number_of_genomes ) {
-                ForesterUtil.fatalError( surfacing.PRG_NAME, "number of external nodes ["
-                        + intree.getNumberOfExternalNodes() + "] of input tree [" + intree_file
-                        + "] is smaller than the number of genomes the be analyzed [" + number_of_genomes + "]" );
+                ForesterUtil.fatalError( surfacing.PRG_NAME,
+                                         "number of external nodes [" + intree.getNumberOfExternalNodes()
+                                                 + "] of input tree [" + intree_file
+                                                 + "] is smaller than the number of genomes the be analyzed ["
+                                                 + number_of_genomes + "]" );
             }
             final StringBuilder parent_names = new StringBuilder();
             final int nodes_lacking_name = SurfacingUtil.getNumberOfNodesLackingName( intree, parent_names );
@@ -1304,8 +1306,8 @@ public class surfacing {
                             .createDomainIdToSecondaryFeaturesMap( secondary_features_map_files[ i ] );
                 }
                 catch ( final IOException e ) {
-                    ForesterUtil.fatalError( surfacing.PRG_NAME, "cannot read secondary features map file: "
-                            + e.getMessage() );
+                    ForesterUtil.fatalError( surfacing.PRG_NAME,
+                                             "cannot read secondary features map file: " + e.getMessage() );
                 }
                 catch ( final Exception e ) {
                     ForesterUtil.fatalError( surfacing.PRG_NAME, "problem with contents of features map file ["
@@ -1778,8 +1780,7 @@ public class surfacing {
             if ( max_allowed_overlap != surfacing.MAX_ALLOWED_OVERLAP_DEFAULT ) {
                 parser.setMaxAllowedOverlap( max_allowed_overlap );
             }
-            parser
-                    .setReturnType( HmmscanPerDomainTableParser.ReturnType.UNORDERED_PROTEIN_DOMAIN_COLLECTION_PER_PROTEIN );
+            parser.setReturnType( HmmscanPerDomainTableParser.ReturnType.UNORDERED_PROTEIN_DOMAIN_COLLECTION_PER_PROTEIN );
             if ( individual_score_cutoffs != null ) {
                 parser.setIndividualScoreCutoffs( individual_score_cutoffs );
             }
@@ -1813,7 +1814,8 @@ public class surfacing {
             System.out.println( "Domains ignored due to individual score cutoffs: "
                     + parser.getDomainsIgnoredDueToIndividualScoreCutoff() );
             log( "Domains ignored due to individual score cutoffs: "
-                    + parser.getDomainsIgnoredDueToIndividualScoreCutoff(), log_writer );
+                         + parser.getDomainsIgnoredDueToIndividualScoreCutoff(),
+                 log_writer );
             System.out.println( "Domains ignored due to E-value                 : "
                     + parser.getDomainsIgnoredDueToEval() );
             log( "Domains ignored due to E-value                 : " + parser.getDomainsIgnoredDueToEval(), log_writer );
@@ -1829,7 +1831,8 @@ public class surfacing {
             System.out.println( "Domains ignored due negative domain filter     : "
                     + parser.getDomainsIgnoredDueToNegativeDomainFilter() );
             log( "Domains ignored due negative domain filter     : "
-                    + parser.getDomainsIgnoredDueToNegativeDomainFilter(), log_writer );
+                         + parser.getDomainsIgnoredDueToNegativeDomainFilter(),
+                 log_writer );
             System.out.println( "Domains ignored due to overlap                 : "
                     + parser.getDomainsIgnoredDueToOverlap() );
             log( "Domains ignored due to overlap                 : " + parser.getDomainsIgnoredDueToOverlap(),
@@ -2082,12 +2085,13 @@ public class surfacing {
             }
             SurfacingUtil.writeMatrixToFile( new File( matrix_output_file
                     + surfacing.MATRIX_MEAN_SCORE_BASED_GENOME_DISTANCE_SUFFIX ), pwgc.getDomainDistanceScoresMeans() );
+            SurfacingUtil
+                    .writeMatrixToFile( new File( matrix_output_file
+                                                + surfacing.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                        pwgc.getSharedBinaryCombinationsBasedDistances() );
             SurfacingUtil.writeMatrixToFile( new File( matrix_output_file
-                    + surfacing.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                    .getSharedBinaryCombinationsBasedDistances() );
-            SurfacingUtil.writeMatrixToFile( new File( matrix_output_file
-                    + surfacing.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                    .getSharedDomainsBasedDistances() );
+                                                     + surfacing.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                             pwgc.getSharedDomainsBasedDistances() );
             final Phylogeny nj_gd = SurfacingUtil.createNjTreeBasedOnMatrixToFile( new File( matrix_output_file
                     + surfacing.NJ_TREE_MEAN_SCORE_BASED_GENOME_DISTANCE_SUFFIX ), pwgc.getDomainDistanceScoresMeans()
                     .get( 0 ) );
@@ -2119,14 +2123,19 @@ public class surfacing {
                                                           jacknife_resamplings,
                                                           jacknife_ratio,
                                                           random_seed );
-                SurfacingUtil.writeMatrixToFile( new File( matrix_output_file + "_"
-                        + ForesterUtil.round( jacknife_ratio, 2 ) + "_" + jacknife_resamplings
-                        + surfacing.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                        .getSharedBinaryCombinationsBasedDistances() );
-                SurfacingUtil.writeMatrixToFile( new File( matrix_output_file + "_"
-                        + ForesterUtil.round( jacknife_ratio, 2 ) + "_" + jacknife_resamplings
-                        + surfacing.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                        .getSharedDomainsBasedDistances() );
+                SurfacingUtil
+                        .writeMatrixToFile( new File( matrix_output_file
+                                                    + "_"
+                                                    + ForesterUtil.round( jacknife_ratio, 2 )
+                                                    + "_"
+                                                    + jacknife_resamplings
+                                                    + surfacing.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                            pwgc.getSharedBinaryCombinationsBasedDistances() );
+                SurfacingUtil
+                        .writeMatrixToFile( new File( matrix_output_file + "_" + ForesterUtil.round( jacknife_ratio, 2 )
+                                                    + "_" + jacknife_resamplings
+                                                    + surfacing.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                            pwgc.getSharedDomainsBasedDistances() );
                 //                if ( infer_species_trees ) {
                 //                    inferSpeciesTrees( new File( output_file + "_" + jacknife_resamplings
                 //                            + INFERRED_SBC_BASED_NJ_SPECIES_TREE_SUFFIX ), pwgc
index 9185725..eeeb5bb 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -67,21 +67,21 @@ import org.forester.surfacing.DomainId;
 import org.forester.surfacing.DomainLengthsTable;
 import org.forester.surfacing.DomainParsimonyCalculator;
 import org.forester.surfacing.DomainSimilarity;
+import org.forester.surfacing.DomainSimilarity.DomainSimilarityScoring;
+import org.forester.surfacing.DomainSimilarity.DomainSimilaritySortField;
 import org.forester.surfacing.DomainSimilarityCalculator;
+import org.forester.surfacing.DomainSimilarityCalculator.Detailedness;
 import org.forester.surfacing.GenomeWideCombinableDomains;
+import org.forester.surfacing.GenomeWideCombinableDomains.GenomeWideCombinableDomainsSortOrder;
 import org.forester.surfacing.MappingResults;
 import org.forester.surfacing.PairwiseDomainSimilarityCalculator;
 import org.forester.surfacing.PairwiseGenomeComparator;
 import org.forester.surfacing.PrintableDomainSimilarity;
+import org.forester.surfacing.PrintableDomainSimilarity.PRINT_OPTION;
 import org.forester.surfacing.Protein;
 import org.forester.surfacing.ProteinCountsBasedPairwiseDomainSimilarityCalculator;
 import org.forester.surfacing.Species;
 import org.forester.surfacing.SurfacingUtil;
-import org.forester.surfacing.DomainSimilarity.DomainSimilarityScoring;
-import org.forester.surfacing.DomainSimilarity.DomainSimilaritySortField;
-import org.forester.surfacing.DomainSimilarityCalculator.Detailedness;
-import org.forester.surfacing.GenomeWideCombinableDomains.GenomeWideCombinableDomainsSortOrder;
-import org.forester.surfacing.PrintableDomainSimilarity.PRINT_OPTION;
 import org.forester.util.BasicTable;
 import org.forester.util.BasicTableParser;
 import org.forester.util.CommandLineArguments;
@@ -517,9 +517,11 @@ public class surfacing_hmmpfam {
                 ForesterUtil.fatalError( surfacing_hmmpfam.PRG_NAME, "input tree [" + intree_file + "] is not rooted" );
             }
             if ( intree.getNumberOfExternalNodes() < number_of_genomes ) {
-                ForesterUtil.fatalError( surfacing_hmmpfam.PRG_NAME, "number of external nodes ["
-                        + intree.getNumberOfExternalNodes() + "] of input tree [" + intree_file
-                        + "] is smaller than the number of genomes the be analyzed [" + number_of_genomes + "]" );
+                ForesterUtil.fatalError( surfacing_hmmpfam.PRG_NAME,
+                                         "number of external nodes [" + intree.getNumberOfExternalNodes()
+                                                 + "] of input tree [" + intree_file
+                                                 + "] is smaller than the number of genomes the be analyzed ["
+                                                 + number_of_genomes + "]" );
             }
             final StringBuilder parent_names = new StringBuilder();
             final int nodes_lacking_name = SurfacingUtil.getNumberOfNodesLackingName( intree, parent_names );
@@ -777,8 +779,7 @@ public class surfacing_hmmpfam {
                 ForesterUtil.fatalError( surfacing_hmmpfam.PRG_NAME, "no value for negative domains filter: -"
                         + surfacing_hmmpfam.FILTER_NEGATIVE_DOMAINS_OPTION + "=<file>" );
             }
-            negative_domains_filter_file = new File( cla
-                    .getOptionValue( surfacing_hmmpfam.FILTER_NEGATIVE_DOMAINS_OPTION ) );
+            negative_domains_filter_file = new File( cla.getOptionValue( surfacing_hmmpfam.FILTER_NEGATIVE_DOMAINS_OPTION ) );
             final String msg = ForesterUtil.isReadableFile( negative_domains_filter_file );
             if ( !ForesterUtil.isEmpty( msg ) ) {
                 ForesterUtil.fatalError( surfacing_hmmpfam.PRG_NAME, "can not read from \""
@@ -1119,8 +1120,8 @@ public class surfacing_hmmpfam {
                 }
             }
             catch ( final IOException e ) {
-                ForesterUtil.fatalError( surfacing_hmmpfam.PRG_NAME, "cannot read from GO OBO file: "
-                        + e.getLocalizedMessage() );
+                ForesterUtil.fatalError( surfacing_hmmpfam.PRG_NAME,
+                                         "cannot read from GO OBO file: " + e.getLocalizedMessage() );
             }
         }
         Map<GoId, GoTerm> go_id_to_term_map = null;
@@ -2027,15 +2028,18 @@ public class surfacing_hmmpfam {
                 matrix_output_file = out_dir + ForesterUtil.FILE_SEPARATOR + matrix_output_file;
                 output_file = new File( out_dir + ForesterUtil.FILE_SEPARATOR + output_file );
             }
-            SurfacingUtil.writeMatrixToFile( new File( matrix_output_file
-                    + surfacing_hmmpfam.MATRIX_MEAN_SCORE_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                    .getDomainDistanceScoresMeans() );
-            SurfacingUtil.writeMatrixToFile( new File( matrix_output_file
-                    + surfacing_hmmpfam.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                    .getSharedBinaryCombinationsBasedDistances() );
-            SurfacingUtil.writeMatrixToFile( new File( matrix_output_file
-                    + surfacing_hmmpfam.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                    .getSharedDomainsBasedDistances() );
+            SurfacingUtil
+                    .writeMatrixToFile( new File( matrix_output_file
+                                                + surfacing_hmmpfam.MATRIX_MEAN_SCORE_BASED_GENOME_DISTANCE_SUFFIX ),
+                                        pwgc.getDomainDistanceScoresMeans() );
+            SurfacingUtil
+                    .writeMatrixToFile( new File( matrix_output_file
+                                                + surfacing_hmmpfam.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                        pwgc.getSharedBinaryCombinationsBasedDistances() );
+            SurfacingUtil
+                    .writeMatrixToFile( new File( matrix_output_file
+                                                + surfacing_hmmpfam.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                        pwgc.getSharedDomainsBasedDistances() );
             final Phylogeny nj_gd = SurfacingUtil.createNjTreeBasedOnMatrixToFile( new File( matrix_output_file
                     + surfacing_hmmpfam.NJ_TREE_MEAN_SCORE_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
                     .getDomainDistanceScoresMeans().get( 0 ) );
@@ -2067,14 +2071,22 @@ public class surfacing_hmmpfam {
                                                           jacknife_resamplings,
                                                           jacknife_ratio,
                                                           random_seed );
-                SurfacingUtil.writeMatrixToFile( new File( matrix_output_file + "_"
-                        + ForesterUtil.round( jacknife_ratio, 2 ) + "_" + jacknife_resamplings
-                        + surfacing_hmmpfam.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                        .getSharedBinaryCombinationsBasedDistances() );
-                SurfacingUtil.writeMatrixToFile( new File( matrix_output_file + "_"
-                        + ForesterUtil.round( jacknife_ratio, 2 ) + "_" + jacknife_resamplings
-                        + surfacing_hmmpfam.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                        .getSharedDomainsBasedDistances() );
+                SurfacingUtil
+                        .writeMatrixToFile( new File( matrix_output_file
+                                                    + "_"
+                                                    + ForesterUtil.round( jacknife_ratio, 2 )
+                                                    + "_"
+                                                    + jacknife_resamplings
+                                                    + surfacing_hmmpfam.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                            pwgc.getSharedBinaryCombinationsBasedDistances() );
+                SurfacingUtil
+                        .writeMatrixToFile( new File( matrix_output_file
+                                                    + "_"
+                                                    + ForesterUtil.round( jacknife_ratio, 2 )
+                                                    + "_"
+                                                    + jacknife_resamplings
+                                                    + surfacing_hmmpfam.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                            pwgc.getSharedDomainsBasedDistances() );
                 //                if ( infer_species_trees ) {
                 //                    inferSpeciesTrees( new File( output_file + "_" + jacknife_resamplings
                 //                            + INFERRED_SBC_BASED_NJ_SPECIES_TREE_SUFFIX ), pwgc
index 07711ee..443191c 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -68,21 +68,21 @@ import org.forester.surfacing.DomainId;
 import org.forester.surfacing.DomainLengthsTable;
 import org.forester.surfacing.DomainParsimonyCalculator;
 import org.forester.surfacing.DomainSimilarity;
+import org.forester.surfacing.DomainSimilarity.DomainSimilarityScoring;
+import org.forester.surfacing.DomainSimilarity.DomainSimilaritySortField;
 import org.forester.surfacing.DomainSimilarityCalculator;
+import org.forester.surfacing.DomainSimilarityCalculator.Detailedness;
 import org.forester.surfacing.GenomeWideCombinableDomains;
+import org.forester.surfacing.GenomeWideCombinableDomains.GenomeWideCombinableDomainsSortOrder;
 import org.forester.surfacing.MappingResults;
 import org.forester.surfacing.PairwiseDomainSimilarityCalculator;
 import org.forester.surfacing.PairwiseGenomeComparator;
 import org.forester.surfacing.PrintableDomainSimilarity;
+import org.forester.surfacing.PrintableDomainSimilarity.PRINT_OPTION;
 import org.forester.surfacing.Protein;
 import org.forester.surfacing.ProteinCountsBasedPairwiseDomainSimilarityCalculator;
 import org.forester.surfacing.Species;
 import org.forester.surfacing.SurfacingUtil;
-import org.forester.surfacing.DomainSimilarity.DomainSimilarityScoring;
-import org.forester.surfacing.DomainSimilarity.DomainSimilaritySortField;
-import org.forester.surfacing.DomainSimilarityCalculator.Detailedness;
-import org.forester.surfacing.GenomeWideCombinableDomains.GenomeWideCombinableDomainsSortOrder;
-import org.forester.surfacing.PrintableDomainSimilarity.PRINT_OPTION;
 import org.forester.util.BasicTable;
 import org.forester.util.BasicTableParser;
 import org.forester.util.CommandLineArguments;
@@ -517,9 +517,11 @@ public class surfacing_old {
                 ForesterUtil.fatalError( surfacing_old.PRG_NAME, "input tree [" + intree_file + "] is not rooted" );
             }
             if ( intree.getNumberOfExternalNodes() < number_of_genomes ) {
-                ForesterUtil.fatalError( surfacing_old.PRG_NAME, "number of external nodes ["
-                        + intree.getNumberOfExternalNodes() + "] of input tree [" + intree_file
-                        + "] is smaller than the number of genomes the be analyzed [" + number_of_genomes + "]" );
+                ForesterUtil.fatalError( surfacing_old.PRG_NAME,
+                                         "number of external nodes [" + intree.getNumberOfExternalNodes()
+                                                 + "] of input tree [" + intree_file
+                                                 + "] is smaller than the number of genomes the be analyzed ["
+                                                 + number_of_genomes + "]" );
             }
             final StringBuilder parent_names = new StringBuilder();
             final int nodes_lacking_name = SurfacingUtil.getNumberOfNodesLackingName( intree, parent_names );
@@ -1113,8 +1115,8 @@ public class surfacing_old {
                 }
             }
             catch ( final IOException e ) {
-                ForesterUtil.fatalError( surfacing_old.PRG_NAME, "cannot read from GO OBO file: "
-                        + e.getLocalizedMessage() );
+                ForesterUtil.fatalError( surfacing_old.PRG_NAME,
+                                         "cannot read from GO OBO file: " + e.getLocalizedMessage() );
             }
         }
         Map<GoId, GoTerm> go_id_to_term_map = null;
@@ -1307,8 +1309,8 @@ public class surfacing_old {
                             .createDomainIdToSecondaryFeaturesMap( secondary_features_map_files[ i ] );
                 }
                 catch ( final IOException e ) {
-                    ForesterUtil.fatalError( surfacing_old.PRG_NAME, "cannot read secondary features map file: "
-                            + e.getMessage() );
+                    ForesterUtil.fatalError( surfacing_old.PRG_NAME,
+                                             "cannot read secondary features map file: " + e.getMessage() );
                 }
                 catch ( final Exception e ) {
                     ForesterUtil.fatalError( surfacing_old.PRG_NAME, "problem with contents of features map file ["
@@ -2021,14 +2023,16 @@ public class surfacing_old {
                 output_file = new File( out_dir + ForesterUtil.FILE_SEPARATOR + output_file );
             }
             SurfacingUtil.writeMatrixToFile( new File( matrix_output_file
-                    + surfacing_old.MATRIX_MEAN_SCORE_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                    .getDomainDistanceScoresMeans() );
-            SurfacingUtil.writeMatrixToFile( new File( matrix_output_file
-                    + surfacing_old.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                    .getSharedBinaryCombinationsBasedDistances() );
-            SurfacingUtil.writeMatrixToFile( new File( matrix_output_file
-                    + surfacing_old.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                    .getSharedDomainsBasedDistances() );
+                                                     + surfacing_old.MATRIX_MEAN_SCORE_BASED_GENOME_DISTANCE_SUFFIX ),
+                                             pwgc.getDomainDistanceScoresMeans() );
+            SurfacingUtil
+                    .writeMatrixToFile( new File( matrix_output_file
+                                                + surfacing_old.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                        pwgc.getSharedBinaryCombinationsBasedDistances() );
+            SurfacingUtil
+                    .writeMatrixToFile( new File( matrix_output_file
+                                                + surfacing_old.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                        pwgc.getSharedDomainsBasedDistances() );
             final Phylogeny nj_gd = SurfacingUtil.createNjTreeBasedOnMatrixToFile( new File( matrix_output_file
                     + surfacing_old.NJ_TREE_MEAN_SCORE_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
                     .getDomainDistanceScoresMeans().get( 0 ) );
@@ -2060,14 +2064,19 @@ public class surfacing_old {
                                                           jacknife_resamplings,
                                                           jacknife_ratio,
                                                           random_seed );
-                SurfacingUtil.writeMatrixToFile( new File( matrix_output_file + "_"
-                        + ForesterUtil.round( jacknife_ratio, 2 ) + "_" + jacknife_resamplings
-                        + surfacing_old.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                        .getSharedBinaryCombinationsBasedDistances() );
-                SurfacingUtil.writeMatrixToFile( new File( matrix_output_file + "_"
-                        + ForesterUtil.round( jacknife_ratio, 2 ) + "_" + jacknife_resamplings
-                        + surfacing_old.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ), pwgc
-                        .getSharedDomainsBasedDistances() );
+                SurfacingUtil
+                        .writeMatrixToFile( new File( matrix_output_file
+                                                    + "_"
+                                                    + ForesterUtil.round( jacknife_ratio, 2 )
+                                                    + "_"
+                                                    + jacknife_resamplings
+                                                    + surfacing_old.MATRIX_SHARED_BIN_COMBINATIONS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                            pwgc.getSharedBinaryCombinationsBasedDistances() );
+                SurfacingUtil
+                        .writeMatrixToFile( new File( matrix_output_file + "_" + ForesterUtil.round( jacknife_ratio, 2 )
+                                                    + "_" + jacknife_resamplings
+                                                    + surfacing_old.MATRIX_SHARED_DOMAINS_BASED_GENOME_DISTANCE_SUFFIX ),
+                                            pwgc.getSharedDomainsBasedDistances() );
                 //                if ( infer_species_trees ) {
                 //                    inferSpeciesTrees( new File( output_file + "_" + jacknife_resamplings
                 //                            + INFERRED_SBC_BASED_NJ_SPECIES_TREE_SUFFIX ), pwgc
index 5817b84..b460916 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -131,8 +131,9 @@ public class ta {
             species_tree = factory.create( species_tree_file, pp )[ 0 ];
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( PRG_NAME, "Failed to read species tree from \"" + gene_tree_file + "\" ["
-                    + e.getMessage() + "]" );
+            ForesterUtil.fatalError( PRG_NAME,
+                                     "Failed to read species tree from \"" + gene_tree_file + "\" [" + e.getMessage()
+                                             + "]" );
         }
         try {
             final PhylogenyFactory factory = ParserBasedPhylogenyFactory.getInstance();
@@ -140,8 +141,9 @@ public class ta {
             gene_tree = factory.create( gene_tree_file, pp )[ 0 ];
         }
         catch ( final IOException e ) {
-            ForesterUtil.fatalError( PRG_NAME, "Failed to read gene tree from \"" + gene_tree_file + "\" ["
-                    + e.getMessage() + "]" );
+            ForesterUtil.fatalError( PRG_NAME,
+                                     "Failed to read gene tree from \"" + gene_tree_file + "\" [" + e.getMessage()
+                                             + "]" );
         }
         gene_tree.setRooted( true );
         species_tree.setRooted( true );
index c1c92cc..c7388c4 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 7d7b9ec..b9bdcb8 100644 (file)
@@ -35,7 +35,7 @@ import org.forester.phylogeny.Phylogeny;
 import org.forester.phylogeny.factories.ParserBasedPhylogenyFactory;
 import org.forester.util.ForesterUtil;
 
-// 
+//
 // java -javaagent:shiftone-jrat.jar -cp
 // $HOME/SOFTWARE_DEV/ECLIPSE_WORKSPACE/forester-atv/java/forester.jar:.
 // org.forester.archaeopteryx.Archaeopteryx
@@ -160,7 +160,9 @@ public final class Archaeopteryx {
             }
             else {
                 MainFrameApplication.createInstance( ParserBasedPhylogenyFactory.getInstance()
-                        .create( s, new PhyloXmlParser() ), conf, title );
+                                                             .create( s, new PhyloXmlParser() ),
+                                                     conf,
+                                                     title );
             }
         }
         // catch ( final IOException ex ) {
index bea6a7b..fd82f35 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b4e4e87..d6d842b 100644 (file)
@@ -110,6 +110,7 @@ public class ArchaeopteryxE extends JApplet implements ActionListener {
     private JMenuItem            _overview_placment_mi;
     private ButtonGroup          _radio_group_1;
 
+    @Override
     public void actionPerformed( final ActionEvent e ) {
         final Object o = e.getSource();
         if ( o == _midpoint_root_item ) {
@@ -328,6 +329,7 @@ public class ArchaeopteryxE extends JApplet implements ActionListener {
         _options_jmenu = MainFrame.createMenu( MainFrame.OPTIONS_HEADER, getConfiguration() );
         _options_jmenu.addChangeListener( new ChangeListener() {
 
+            @Override
             public void stateChanged( final ChangeEvent e ) {
                 MainFrame.setOvPlacementColorChooseMenuItem( _overview_placment_mi, getCurrentTreePanel() );
                 MainFrame.setTextColorChooseMenuItem( _switch_colors_mi, getCurrentTreePanel() );
index 68911e8..600eb04 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index cc76278..2866b14 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -81,15 +81,18 @@ final class ColorSchemeChooser extends JDialog implements ActionListener {
         _selector.setMaximumRowCount( list.size() );
         _selector.getModel().addListDataListener( new ListDataListener() {
 
+            @Override
             public void contentsChanged( final ListDataEvent e ) {
                 final int selection = _selector.getSelectedIndex();
                 changeDialogColors( selection );
             }
 
+            @Override
             public void intervalAdded( final ListDataEvent e ) {
                 // Not needed.
             }
 
+            @Override
             public void intervalRemoved( final ListDataEvent e ) {
                 // Not needed.
             }
@@ -117,6 +120,7 @@ final class ColorSchemeChooser extends JDialog implements ActionListener {
         _ok_btn = new JButton( "OK" );
         _ok_btn.addActionListener( new ActionListener() {
 
+            @Override
             public void actionPerformed( final ActionEvent e ) {
                 ok();
             }
@@ -125,6 +129,7 @@ final class ColorSchemeChooser extends JDialog implements ActionListener {
         _cancel_btn = new JButton( "Cancel" );
         _cancel_btn.addActionListener( new ActionListener() {
 
+            @Override
             public void actionPerformed( final ActionEvent e ) {
                 cancel();
             }
@@ -135,6 +140,7 @@ final class ColorSchemeChooser extends JDialog implements ActionListener {
         setCurrentColor( colorset.getCurrentColorScheme() );
     }
 
+    @Override
     public void actionPerformed( final ActionEvent e ) {
         // Not needed.
     }
index 2333e77..d9a657d 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -1235,8 +1235,9 @@ public final class Configuration {
                 }
                 else if ( key.equals( WEB_LINK_KEY ) ) {
                     if ( st.countTokens() == 3 ) {
-                        createWebLink( ( String ) st.nextElement(), ( String ) st.nextElement(), ( String ) st
-                                .nextElement() );
+                        createWebLink( ( String ) st.nextElement(),
+                                       ( String ) st.nextElement(),
+                                       ( String ) st.nextElement() );
                     }
                     else {
                         ForesterUtil.printWarningMessage( Constants.PRG_NAME,
index 94dfc5d..243a526 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d3b56e2..9729cb8 100644 (file)
@@ -4,7 +4,7 @@
 //
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -14,7 +14,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -172,6 +172,7 @@ final class ControlPanel extends JPanel implements ActionListener {
     /**
      * Handle an action.
      */
+    @Override
     public void actionPerformed( final ActionEvent e ) {
         try {
             final TreePanel tp = getMainPanel().getCurrentTreePanel();
@@ -586,10 +587,10 @@ final class ControlPanel extends JPanel implements ActionListener {
         add( horizGrid );
         add( getSequenceRelationBox() );
         if ( _configuration.doDisplayOption( Configuration.show_relation_confidence ) ) {
-            addCheckbox( Configuration.show_relation_confidence, _configuration
-                    .getDisplayTitle( Configuration.show_relation_confidence ) );
-            setCheckbox( Configuration.show_relation_confidence, _configuration
-                    .doCheckOption( Configuration.show_relation_confidence ) );
+            addCheckbox( Configuration.show_relation_confidence,
+                         _configuration.getDisplayTitle( Configuration.show_relation_confidence ) );
+            setCheckbox( Configuration.show_relation_confidence,
+                         _configuration.doCheckOption( Configuration.show_relation_confidence ) );
         }
     }// addSequenceRelationBlock
 
@@ -1258,8 +1259,8 @@ final class ControlPanel extends JPanel implements ActionListener {
         int cb_index = 0;
         if ( _configuration.doDisplayClickToOption( Configuration.display_node_data ) ) {
             _show_data_item = cb_index;
-            addClickToOption( Configuration.display_node_data, _configuration
-                    .getClickToTitle( Configuration.display_node_data ) );
+            addClickToOption( Configuration.display_node_data,
+                              _configuration.getClickToTitle( Configuration.display_node_data ) );
             if ( default_option == Configuration.display_node_data ) {
                 selected_index = cb_index;
             }
@@ -1267,8 +1268,8 @@ final class ControlPanel extends JPanel implements ActionListener {
         }
         if ( _configuration.doDisplayClickToOption( Configuration.collapse_uncollapse ) ) {
             _collapse_cb_item = cb_index;
-            addClickToOption( Configuration.collapse_uncollapse, _configuration
-                    .getClickToTitle( Configuration.collapse_uncollapse ) );
+            addClickToOption( Configuration.collapse_uncollapse,
+                              _configuration.getClickToTitle( Configuration.collapse_uncollapse ) );
             if ( default_option == Configuration.collapse_uncollapse ) {
                 selected_index = cb_index;
             }
@@ -1333,8 +1334,8 @@ final class ControlPanel extends JPanel implements ActionListener {
             }
             if ( _configuration.doDisplayClickToOption( Configuration.copy_subtree ) ) {
                 _copy_subtree_item = cb_index;
-                addClickToOption( Configuration.copy_subtree, _configuration
-                        .getClickToTitle( Configuration.copy_subtree ) );
+                addClickToOption( Configuration.copy_subtree,
+                                  _configuration.getClickToTitle( Configuration.copy_subtree ) );
                 if ( default_option == Configuration.copy_subtree ) {
                     selected_index = cb_index;
                 }
@@ -1342,8 +1343,8 @@ final class ControlPanel extends JPanel implements ActionListener {
             }
             if ( _configuration.doDisplayClickToOption( Configuration.paste_subtree ) ) {
                 _paste_subtree_item = cb_index;
-                addClickToOption( Configuration.paste_subtree, _configuration
-                        .getClickToTitle( Configuration.paste_subtree ) );
+                addClickToOption( Configuration.paste_subtree,
+                                  _configuration.getClickToTitle( Configuration.paste_subtree ) );
                 if ( default_option == Configuration.paste_subtree ) {
                     selected_index = cb_index;
                 }
@@ -1351,8 +1352,8 @@ final class ControlPanel extends JPanel implements ActionListener {
             }
             if ( _configuration.doDisplayClickToOption( Configuration.delete_subtree_or_node ) ) {
                 _delete_node_or_subtree_item = cb_index;
-                addClickToOption( Configuration.delete_subtree_or_node, _configuration
-                        .getClickToTitle( Configuration.delete_subtree_or_node ) );
+                addClickToOption( Configuration.delete_subtree_or_node,
+                                  _configuration.getClickToTitle( Configuration.delete_subtree_or_node ) );
                 if ( default_option == Configuration.delete_subtree_or_node ) {
                     selected_index = cb_index;
                 }
@@ -1360,8 +1361,8 @@ final class ControlPanel extends JPanel implements ActionListener {
             }
             if ( _configuration.doDisplayClickToOption( Configuration.add_new_node ) ) {
                 _add_new_node_item = cb_index;
-                addClickToOption( Configuration.add_new_node, _configuration
-                        .getClickToTitle( Configuration.add_new_node ) );
+                addClickToOption( Configuration.add_new_node,
+                                  _configuration.getClickToTitle( Configuration.add_new_node ) );
                 if ( default_option == Configuration.add_new_node ) {
                     selected_index = cb_index;
                 }
@@ -1369,8 +1370,8 @@ final class ControlPanel extends JPanel implements ActionListener {
             }
             if ( _configuration.doDisplayClickToOption( Configuration.edit_node_data ) ) {
                 _edit_node_data_item = cb_index;
-                addClickToOption( Configuration.edit_node_data, _configuration
-                        .getClickToTitle( Configuration.edit_node_data ) );
+                addClickToOption( Configuration.edit_node_data,
+                                  _configuration.getClickToTitle( Configuration.edit_node_data ) );
                 if ( default_option == Configuration.edit_node_data ) {
                     selected_index = cb_index;
                 }
@@ -1452,38 +1453,38 @@ final class ControlPanel extends JPanel implements ActionListener {
 
     private void setupDisplayCheckboxes() {
         if ( _configuration.doDisplayOption( Configuration.display_as_phylogram ) ) {
-            addCheckbox( Configuration.display_as_phylogram, _configuration
-                    .getDisplayTitle( Configuration.display_as_phylogram ) );
-            setCheckbox( Configuration.display_as_phylogram, _configuration
-                    .doCheckOption( Configuration.display_as_phylogram ) );
+            addCheckbox( Configuration.display_as_phylogram,
+                         _configuration.getDisplayTitle( Configuration.display_as_phylogram ) );
+            setCheckbox( Configuration.display_as_phylogram,
+                         _configuration.doCheckOption( Configuration.display_as_phylogram ) );
         }
         if ( _configuration.doDisplayOption( Configuration.dynamically_hide_data ) ) {
-            addCheckbox( Configuration.dynamically_hide_data, _configuration
-                    .getDisplayTitle( Configuration.dynamically_hide_data ) );
-            setCheckbox( Configuration.dynamically_hide_data, _configuration
-                    .doCheckOption( Configuration.dynamically_hide_data ) );
+            addCheckbox( Configuration.dynamically_hide_data,
+                         _configuration.getDisplayTitle( Configuration.dynamically_hide_data ) );
+            setCheckbox( Configuration.dynamically_hide_data,
+                         _configuration.doCheckOption( Configuration.dynamically_hide_data ) );
         }
         if ( _configuration.doDisplayOption( Configuration.node_data_popup ) ) {
             addCheckbox( Configuration.node_data_popup, _configuration.getDisplayTitle( Configuration.node_data_popup ) );
             setCheckbox( Configuration.node_data_popup, _configuration.doCheckOption( Configuration.node_data_popup ) );
         }
         if ( _configuration.doDisplayOption( Configuration.display_internal_data ) ) {
-            addCheckbox( Configuration.display_internal_data, _configuration
-                    .getDisplayTitle( Configuration.display_internal_data ) );
-            setCheckbox( Configuration.display_internal_data, _configuration
-                    .doCheckOption( Configuration.display_internal_data ) );
+            addCheckbox( Configuration.display_internal_data,
+                         _configuration.getDisplayTitle( Configuration.display_internal_data ) );
+            setCheckbox( Configuration.display_internal_data,
+                         _configuration.doCheckOption( Configuration.display_internal_data ) );
         }
         if ( _configuration.doDisplayOption( Configuration.color_according_to_species ) ) {
-            addCheckbox( Configuration.color_according_to_species, _configuration
-                    .getDisplayTitle( Configuration.color_according_to_species ) );
-            setCheckbox( Configuration.color_according_to_species, _configuration
-                    .doCheckOption( Configuration.color_according_to_species ) );
+            addCheckbox( Configuration.color_according_to_species,
+                         _configuration.getDisplayTitle( Configuration.color_according_to_species ) );
+            setCheckbox( Configuration.color_according_to_species,
+                         _configuration.doCheckOption( Configuration.color_according_to_species ) );
         }
         if ( _configuration.doDisplayOption( Configuration.color_according_to_annotation ) ) {
-            addCheckbox( Configuration.color_according_to_annotation, _configuration
-                    .getDisplayTitle( Configuration.color_according_to_annotation ) );
-            setCheckbox( Configuration.color_according_to_annotation, _configuration
-                    .doCheckOption( Configuration.color_according_to_annotation ) );
+            addCheckbox( Configuration.color_according_to_annotation,
+                         _configuration.getDisplayTitle( Configuration.color_according_to_annotation ) );
+            setCheckbox( Configuration.color_according_to_annotation,
+                         _configuration.doCheckOption( Configuration.color_according_to_annotation ) );
         }
         if ( _configuration.doDisplayOption( Configuration.color_branches ) ) {
             addCheckbox( Configuration.color_branches, _configuration.getDisplayTitle( Configuration.color_branches ) );
@@ -1508,74 +1509,74 @@ final class ControlPanel extends JPanel implements ActionListener {
             setCheckbox( Configuration.show_tax_code, _configuration.doCheckOption( Configuration.show_tax_code ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_taxonomy_scientific_names ) ) {
-            addCheckbox( Configuration.show_taxonomy_scientific_names, _configuration
-                    .getDisplayTitle( Configuration.show_taxonomy_scientific_names ) );
-            setCheckbox( Configuration.show_taxonomy_scientific_names, _configuration
-                    .doCheckOption( Configuration.show_taxonomy_scientific_names ) );
+            addCheckbox( Configuration.show_taxonomy_scientific_names,
+                         _configuration.getDisplayTitle( Configuration.show_taxonomy_scientific_names ) );
+            setCheckbox( Configuration.show_taxonomy_scientific_names,
+                         _configuration.doCheckOption( Configuration.show_taxonomy_scientific_names ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_taxonomy_common_names ) ) {
-            addCheckbox( Configuration.show_taxonomy_common_names, _configuration
-                    .getDisplayTitle( Configuration.show_taxonomy_common_names ) );
-            setCheckbox( Configuration.show_taxonomy_common_names, _configuration
-                    .doCheckOption( Configuration.show_taxonomy_common_names ) );
+            addCheckbox( Configuration.show_taxonomy_common_names,
+                         _configuration.getDisplayTitle( Configuration.show_taxonomy_common_names ) );
+            setCheckbox( Configuration.show_taxonomy_common_names,
+                         _configuration.doCheckOption( Configuration.show_taxonomy_common_names ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_taxonomy_images ) ) {
-            addCheckbox( Configuration.show_taxonomy_images, _configuration
-                    .getDisplayTitle( Configuration.show_taxonomy_images ) );
-            setCheckbox( Configuration.show_taxonomy_images, _configuration
-                    .doCheckOption( Configuration.show_taxonomy_images ) );
+            addCheckbox( Configuration.show_taxonomy_images,
+                         _configuration.getDisplayTitle( Configuration.show_taxonomy_images ) );
+            setCheckbox( Configuration.show_taxonomy_images,
+                         _configuration.doCheckOption( Configuration.show_taxonomy_images ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_gene_symbols ) ) {
-            addCheckbox( Configuration.show_gene_symbols, _configuration
-                    .getDisplayTitle( Configuration.show_gene_symbols ) );
-            setCheckbox( Configuration.show_gene_symbols, _configuration
-                    .doCheckOption( Configuration.show_gene_symbols ) );
+            addCheckbox( Configuration.show_gene_symbols,
+                         _configuration.getDisplayTitle( Configuration.show_gene_symbols ) );
+            setCheckbox( Configuration.show_gene_symbols,
+                         _configuration.doCheckOption( Configuration.show_gene_symbols ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_gene_names ) ) {
             addCheckbox( Configuration.show_gene_names, _configuration.getDisplayTitle( Configuration.show_gene_names ) );
             setCheckbox( Configuration.show_gene_names, _configuration.doCheckOption( Configuration.show_gene_names ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_sequence_acc ) ) {
-            addCheckbox( Configuration.show_sequence_acc, _configuration
-                    .getDisplayTitle( Configuration.show_sequence_acc ) );
-            setCheckbox( Configuration.show_sequence_acc, _configuration
-                    .doCheckOption( Configuration.show_sequence_acc ) );
+            addCheckbox( Configuration.show_sequence_acc,
+                         _configuration.getDisplayTitle( Configuration.show_sequence_acc ) );
+            setCheckbox( Configuration.show_sequence_acc,
+                         _configuration.doCheckOption( Configuration.show_sequence_acc ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_annotation ) ) {
             addCheckbox( Configuration.show_annotation, _configuration.getDisplayTitle( Configuration.show_annotation ) );
             setCheckbox( Configuration.show_annotation, _configuration.doCheckOption( Configuration.show_annotation ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_binary_characters ) ) {
-            addCheckbox( Configuration.show_binary_characters, _configuration
-                    .getDisplayTitle( Configuration.show_binary_characters ) );
-            setCheckbox( Configuration.show_binary_characters, _configuration
-                    .doCheckOption( Configuration.show_binary_characters ) );
+            addCheckbox( Configuration.show_binary_characters,
+                         _configuration.getDisplayTitle( Configuration.show_binary_characters ) );
+            setCheckbox( Configuration.show_binary_characters,
+                         _configuration.doCheckOption( Configuration.show_binary_characters ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_binary_character_counts ) ) {
-            addCheckbox( Configuration.show_binary_character_counts, _configuration
-                    .getDisplayTitle( Configuration.show_binary_character_counts ) );
-            setCheckbox( Configuration.show_binary_character_counts, _configuration
-                    .doCheckOption( Configuration.show_binary_character_counts ) );
+            addCheckbox( Configuration.show_binary_character_counts,
+                         _configuration.getDisplayTitle( Configuration.show_binary_character_counts ) );
+            setCheckbox( Configuration.show_binary_character_counts,
+                         _configuration.doCheckOption( Configuration.show_binary_character_counts ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_domain_architectures ) ) {
-            addCheckbox( Configuration.show_domain_architectures, _configuration
-                    .getDisplayTitle( Configuration.show_domain_architectures ) );
-            setCheckbox( Configuration.show_domain_architectures, _configuration
-                    .doCheckOption( Configuration.show_domain_architectures ) );
+            addCheckbox( Configuration.show_domain_architectures,
+                         _configuration.getDisplayTitle( Configuration.show_domain_architectures ) );
+            setCheckbox( Configuration.show_domain_architectures,
+                         _configuration.doCheckOption( Configuration.show_domain_architectures ) );
         }
         if ( _configuration.doDisplayOption( Configuration.write_confidence_values ) ) {
-            addCheckbox( Configuration.write_confidence_values, _configuration
-                    .getDisplayTitle( Configuration.write_confidence_values ) );
-            setCheckbox( Configuration.write_confidence_values, _configuration
-                    .doCheckOption( Configuration.write_confidence_values ) );
+            addCheckbox( Configuration.write_confidence_values,
+                         _configuration.getDisplayTitle( Configuration.write_confidence_values ) );
+            setCheckbox( Configuration.write_confidence_values,
+                         _configuration.doCheckOption( Configuration.write_confidence_values ) );
         }
         if ( _configuration.doDisplayOption( Configuration.write_events ) ) {
             addCheckbox( Configuration.write_events, _configuration.getDisplayTitle( Configuration.write_events ) );
             setCheckbox( Configuration.write_events, _configuration.doCheckOption( Configuration.write_events ) );
         }
         if ( _configuration.doDisplayOption( Configuration.show_vector_data ) ) {
-            addCheckbox( Configuration.show_vector_data, _configuration
-                    .getDisplayTitle( Configuration.show_vector_data ) );
+            addCheckbox( Configuration.show_vector_data,
+                         _configuration.getDisplayTitle( Configuration.show_vector_data ) );
             setCheckbox( Configuration.show_vector_data, _configuration.doCheckOption( Configuration.show_vector_data ) );
         }
     }
@@ -1694,8 +1695,9 @@ final class ControlPanel extends JPanel implements ActionListener {
         for( final TreePanel tree_panel : _mainpanel.getTreePanels() ) {
             if ( tree_panel != null ) {
                 tree_panel.validate();
-                tree_panel.setParametersForPainting( _mainpanel.getSizeOfViewport().width, _mainpanel
-                        .getSizeOfViewport().height, true );
+                tree_panel.setParametersForPainting( _mainpanel.getSizeOfViewport().width,
+                                                     _mainpanel.getSizeOfViewport().height,
+                                                     true );
                 tree_panel.resetPreferredSize();
                 tree_panel.repaint();
             }
index d319fa1..9c9eedd 100644 (file)
@@ -126,6 +126,7 @@ public class FontChooser extends JDialog implements ActionListener, ListSelectio
         this( new Font( font_name, font_style, size ) );
     }
 
+    @Override
     public void actionPerformed( final ActionEvent e ) {
         if ( e.getSource() == _fonts_tf ) {
             boolean found = false;
@@ -262,6 +263,7 @@ public class FontChooser extends JDialog implements ActionListener, ListSelectio
         return _option;
     }
 
+    @Override
     public void valueChanged( final ListSelectionEvent e ) {
         if ( e.getSource() == _font_list ) {
             if ( _font_list.getSelectedValue() != null ) {
index f9d5d89..2618943 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 48c52e8..4ade5da 100644 (file)
@@ -4,7 +4,7 @@
 //
 // Copyright (C) 2008-2010 Christian M. Zmasek
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -14,7 +14,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -874,9 +874,8 @@ public abstract class MainFrame extends JFrame implements ActionListener {
         options.setAntialiasPrint( ( _antialias_print_cbmi != null ) && _antialias_print_cbmi.isSelected() );
         options.setPrintBlackAndWhite( ( _print_black_and_white_cbmi != null )
                 && _print_black_and_white_cbmi.isSelected() );
-        options
-                .setInternalNumberAreConfidenceForNhParsing( ( _internal_number_are_confidence_for_nh_parsing_cbmi != null )
-                        && _internal_number_are_confidence_for_nh_parsing_cbmi.isSelected() );
+        options.setInternalNumberAreConfidenceForNhParsing( ( _internal_number_are_confidence_for_nh_parsing_cbmi != null )
+                && _internal_number_are_confidence_for_nh_parsing_cbmi.isSelected() );
         options.setExtractPfamTaxonomyCodesInNhParsing( ( _extract_pfam_style_tax_codes_cbmi != null )
                 && _extract_pfam_style_tax_codes_cbmi.isSelected() );
         options.setReplaceUnderscoresInNhParsing( ( _replace_underscores_cbmi != null )
@@ -1064,8 +1063,7 @@ public abstract class MainFrame extends JFrame implements ActionListener {
         sb.append( "Mouse wheel+Ctrl changes the text size.\n" );
         sb.append( "Mouse wheel+Shift controls zooming in vertical direction only.\n" );
         sb.append( "Use the buttons on the control panel to zoom the tree in and out, horizontally or vertically.\n" );
-        sb
-                .append( "The entire tree can be fitted into the window by clicking the \"F\" button, or by pressing F, Delete, or Home.\n" );
+        sb.append( "The entire tree can be fitted into the window by clicking the \"F\" button, or by pressing F, Delete, or Home.\n" );
         sb.append( "The up, down, left, and right keys can be used to move the visible part (if zoomed in).\n" );
         sb.append( "Up, down, left, and right+Shift can be used to control zooming horizontally and vertically.\n" );
         sb.append( "Plus and minus keys+Ctrl change the text size; F+Ctrl, Delete+Ctrl, or Home+Ctrl resets it.\n\n" );
@@ -1076,8 +1074,7 @@ public abstract class MainFrame extends JFrame implements ActionListener {
         sb.append( "Memory problems (Java heap space error)\n" );
         sb.append( "---------------------------------------\n" );
         sb.append( "Since the Java default memory allocation is quite small, it might by necessary (for trees\n" );
-        sb
-                .append( "with more than approximately 5000 external nodes) to increase the memory which Java can use, with\n" );
+        sb.append( "with more than approximately 5000 external nodes) to increase the memory which Java can use, with\n" );
         sb.append( "the '-Xmx' Java command line option. For example:\n" );
         sb.append( "java -Xms32m -Xmx256m -cp path\\to\\forester.jar org.forester.archaeopteryx.Archaeopteryx\n\n" );
         if ( ( weblinks != null ) && ( weblinks.size() > 0 ) ) {
index 3ac938c..0b89e48 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -73,12 +73,11 @@ public final class MainFrameApplet extends MainFrame {
             catch ( final Exception e ) {
                 ForesterUtil.printErrorMessage( ArchaeopteryxA.NAME, e.toString() );
                 e.printStackTrace();
-                JOptionPane
-                        .showMessageDialog( this,
-                                            ArchaeopteryxA.NAME + ": Could not create URL from: \""
-                                                    + _applet.getUrlString() + "\"\nError: " + e,
-                                            "Failed to create URL",
-                                            JOptionPane.ERROR_MESSAGE );
+                JOptionPane.showMessageDialog( this,
+                                               ArchaeopteryxA.NAME + ": Could not create URL from: \""
+                                                       + _applet.getUrlString() + "\"\nError: " + e,
+                                               "Failed to create URL",
+                                               JOptionPane.ERROR_MESSAGE );
                 close();
             }
         }
index a6e2569..5c26a5a 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -94,9 +94,9 @@ import org.forester.util.BasicTable;
 import org.forester.util.BasicTableParser;
 import org.forester.util.DescriptiveStatistics;
 import org.forester.util.ForesterUtil;
-import org.forester.util.WindowsUtils;
 import org.forester.util.ForesterUtil.PhylogenyNodeField;
 import org.forester.util.ForesterUtil.TAXONOMY_EXTRACTION;
+import org.forester.util.WindowsUtils;
 
 class DefaultFilter extends FileFilter {
 
@@ -1098,8 +1098,9 @@ public final class MainFrameApplication extends MainFrame {
         if ( ( _mainpanel.getCurrentPhylogeny() == null ) || ( _mainpanel.getCurrentPhylogeny().isEmpty() ) ) {
             return;
         }
-        final MainPanelEdit a = new MainPanelEdit( this, _mainpanel.getCurrentTreePanel(), _mainpanel
-                .getCurrentPhylogeny() );
+        final MainPanelEdit a = new MainPanelEdit( this,
+                                                   _mainpanel.getCurrentTreePanel(),
+                                                   _mainpanel.getCurrentPhylogeny() );
         new Thread( a ).start();
     }
 
@@ -1115,8 +1116,9 @@ public final class MainFrameApplication extends MainFrame {
             return;
         }
         final Phylogeny phy = _mainpanel.getCurrentPhylogeny().copy();
-        final AncestralTaxonomyInferrer inferrer = new AncestralTaxonomyInferrer( this, _mainpanel
-                .getCurrentTreePanel(), phy );
+        final AncestralTaxonomyInferrer inferrer = new AncestralTaxonomyInferrer( this,
+                                                                                  _mainpanel.getCurrentTreePanel(),
+                                                                                  phy );
         new Thread( inferrer ).start();
     }
 
@@ -1130,8 +1132,7 @@ public final class MainFrameApplication extends MainFrame {
                 if ( getMsa() != null ) {
                     final PhylogeneticInferrer inferrer = new PhylogeneticInferrer( getMsa(),
                                                                                     getPhylogeneticInferenceOptions()
-                                                                                            .copy(),
-                                                                                    this );
+                                                                                            .copy(), this );
                     new Thread( inferrer ).start();
                 }
                 else {
@@ -1145,8 +1146,7 @@ public final class MainFrameApplication extends MainFrame {
                 if ( getSeqs() != null ) {
                     final PhylogeneticInferrer inferrer = new PhylogeneticInferrer( getSeqs(),
                                                                                     getPhylogeneticInferenceOptions()
-                                                                                            .copy(),
-                                                                                    this );
+                                                                                            .copy(), this );
                     new Thread( inferrer ).start();
                 }
                 else {
@@ -1374,8 +1374,9 @@ public final class MainFrameApplication extends MainFrame {
         if ( getCurrentTreePanel() != null ) {
             final Phylogeny phy = getCurrentTreePanel().getPhylogeny();
             if ( ( phy != null ) && !phy.isEmpty() ) {
-                final TaxonomyDataObtainer t = new TaxonomyDataObtainer( this, _mainpanel.getCurrentTreePanel(), phy
-                        .copy() );
+                final TaxonomyDataObtainer t = new TaxonomyDataObtainer( this,
+                                                                         _mainpanel.getCurrentTreePanel(),
+                                                                         phy.copy() );
                 new Thread( t ).start();
             }
         }
@@ -1991,8 +1992,11 @@ public final class MainFrameApplication extends MainFrame {
                         ForesterUtil.transferInternalNodeNamesToConfidence( phy );
                     }
                 }
-                Util.addPhylogeniesToTabs( phys, new File( url.getFile() ).getName(), new File( url.getFile() )
-                        .toString(), getConfiguration(), getMainPanel() );
+                Util.addPhylogeniesToTabs( phys,
+                                           new File( url.getFile() ).getName(),
+                                           new File( url.getFile() ).toString(),
+                                           getConfiguration(),
+                                           getMainPanel() );
                 _mainpanel.getControlPanel().showWhole();
             }
         }
@@ -2574,8 +2578,7 @@ class TolFilter extends FileFilter {
     public boolean accept( final File f ) {
         final String file_name = f.getName().trim().toLowerCase();
         return ( file_name.endsWith( ".tol" ) || file_name.endsWith( ".tolxml" ) || file_name.endsWith( ".zip" ) || f
-                .isDirectory() )
-                && ( !file_name.endsWith( ".xml.zip" ) );
+                .isDirectory() ) && ( !file_name.endsWith( ".xml.zip" ) );
     }
 
     @Override
index 42332d4..921ff91 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -329,6 +329,7 @@ public class MainPanel extends JPanel implements ComponentListener {
         _tabbed_pane.addChangeListener( new ChangeListener() {
 
             // This method is called whenever the selected tab changes
+            @Override
             public void stateChanged( final ChangeEvent evt ) {
                 final JTabbedPane pane = ( JTabbedPane ) evt.getSource();
                 getControlPanel().tabChanged();
index 226c2db..4d4d684 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b2b7bdd..0728da1 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -66,15 +66,13 @@ public class MainPanelEdit implements Runnable {
             if ( ( node.getNodeData().getSequences() != null ) && !node.getNodeData().getSequences().isEmpty() ) {
                 for( final Sequence seq : node.getNodeData().getSequences() ) {
                     if ( ( ( seq.getAccession() != null ) && !ForesterUtil.isEmpty( seq.getAccession().getValue() ) && ( seq
-                            .getAnnotations() == null ) )
-                            || seq.getAnnotations().isEmpty() ) {
+                            .getAnnotations() == null ) ) || seq.getAnnotations().isEmpty() ) {
                         final Accession acc = seq.getAccession();
                         try {
                             final URL url = new URL( "http://www.ebi.ac.uk/QuickGO/GAnnotation?protein="
                                     + acc.getValue() + "&format=tsv" );
                             final HttpURLConnection url_connection = ( HttpURLConnection ) url.openConnection();
-                            final BufferedReader br = new BufferedReader( new InputStreamReader( url_connection
-                                    .getInputStream() ) );
+                            final BufferedReader br = new BufferedReader( new InputStreamReader( url_connection.getInputStream() ) );
                             final List<String> columns = Arrays.asList( br.readLine().split( "\t" ) );
                             System.out.println( columns );
                             final int db_index = columns.indexOf( DB );
index 628d0b6..eb6e64f 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index beab4f2..9780d25 100644 (file)
@@ -220,12 +220,18 @@ class NodeEditPanel extends JPanel {
         category = new DefaultMutableTreeNode( name );
         top.add( category );
         addSubelementEditable( category, NodePanel.DATE_DESCRIPTION, date.getDesc(), PHYLOXML_TAG.DATE_DESCRIPTION );
-        addSubelementEditable( category, NodePanel.DATE_VALUE, String.valueOf( date.getValue() != null ? date
-                .getValue() : "" ), PHYLOXML_TAG.DATE_VALUE );
-        addSubelementEditable( category, NodePanel.DATE_MIN, String
-                .valueOf( date.getMin() != null ? date.getMin() : "" ), PHYLOXML_TAG.DATE_MIN );
-        addSubelementEditable( category, NodePanel.DATE_MAX, String
-                .valueOf( date.getMax() != null ? date.getMax() : "" ), PHYLOXML_TAG.DATE_MAX );
+        addSubelementEditable( category,
+                               NodePanel.DATE_VALUE,
+                               String.valueOf( date.getValue() != null ? date.getValue() : "" ),
+                               PHYLOXML_TAG.DATE_VALUE );
+        addSubelementEditable( category,
+                               NodePanel.DATE_MIN,
+                               String.valueOf( date.getMin() != null ? date.getMin() : "" ),
+                               PHYLOXML_TAG.DATE_MIN );
+        addSubelementEditable( category,
+                               NodePanel.DATE_MAX,
+                               String.valueOf( date.getMax() != null ? date.getMax() : "" ),
+                               PHYLOXML_TAG.DATE_MAX );
         addSubelementEditable( category, NodePanel.DATE_UNIT, date.getUnit(), PHYLOXML_TAG.DATE_UNIT );
     }
 
@@ -247,14 +253,22 @@ class NodeEditPanel extends JPanel {
                                NodePanel.DIST_GEODETIC_DATUM,
                                p0.getGeodeticDatum(),
                                PHYLOXML_TAG.DIST_GEODETIC );
-        addSubelementEditable( category, NodePanel.DIST_LATITUDE, String.valueOf( p0.getLatitude() != null ? p0
-                .getLatitude() : "" ), PHYLOXML_TAG.DIST_LAT );
-        addSubelementEditable( category, NodePanel.DIST_LONGITUDE, String.valueOf( p0.getLongitude() != null ? p0
-                .getLongitude() : "" ), PHYLOXML_TAG.DIST_LONG );
-        addSubelementEditable( category, NodePanel.DIST_ALTITUDE, String.valueOf( p0.getAltitude() != null ? p0
-                .getAltitude() : "" ), PHYLOXML_TAG.DIST_ALT );
-        addSubelementEditable( category, NodePanel.DIST_ALT_UNIT, String.valueOf( p0.getAltiudeUnit() != null ? p0
-                .getAltiudeUnit() : "" ), PHYLOXML_TAG.DIST_ALT_UNIT );
+        addSubelementEditable( category,
+                               NodePanel.DIST_LATITUDE,
+                               String.valueOf( p0.getLatitude() != null ? p0.getLatitude() : "" ),
+                               PHYLOXML_TAG.DIST_LAT );
+        addSubelementEditable( category,
+                               NodePanel.DIST_LONGITUDE,
+                               String.valueOf( p0.getLongitude() != null ? p0.getLongitude() : "" ),
+                               PHYLOXML_TAG.DIST_LONG );
+        addSubelementEditable( category,
+                               NodePanel.DIST_ALTITUDE,
+                               String.valueOf( p0.getAltitude() != null ? p0.getAltitude() : "" ),
+                               PHYLOXML_TAG.DIST_ALT );
+        addSubelementEditable( category,
+                               NodePanel.DIST_ALT_UNIT,
+                               String.valueOf( p0.getAltiudeUnit() != null ? p0.getAltiudeUnit() : "" ),
+                               PHYLOXML_TAG.DIST_ALT_UNIT );
     }
 
     private void addEvents( final DefaultMutableTreeNode top, Event events, final String name ) {
@@ -275,9 +289,7 @@ class NodeEditPanel extends JPanel {
                                PHYLOXML_TAG.EVENTS_SPECIATIONS );
         addSubelementEditable( category,
                                NodePanel.EVENTS_GENE_LOSSES,
-                               String
-                                       .valueOf( events.getNumberOfGeneLosses() >= 0 ? events.getNumberOfGeneLosses()
-                                               : 0 ),
+                               String.valueOf( events.getNumberOfGeneLosses() >= 0 ? events.getNumberOfGeneLosses() : 0 ),
                                PHYLOXML_TAG.EVENTS_GENE_LOSSES );
     }
 
@@ -911,8 +923,8 @@ class NodeEditPanel extends JPanel {
                                                    p.getLatitude(),
                                                    p.getLongitude(),
                                                    new_value,
-                                                   ForesterUtil.isEmpty( p.getAltiudeUnit() ) ? "?" : p
-                                                           .getAltiudeUnit() );
+                                                   ForesterUtil.isEmpty( p.getAltiudeUnit() ) ? "?"
+                                                           : p.getAltiudeUnit() );
                     ps.set( 0, p_new );
                 }
                 break;
@@ -927,8 +939,11 @@ class NodeEditPanel extends JPanel {
                 if ( !ForesterUtil.isEmpty( value ) ) {
                     final List<Point> ps = obtainPoints();
                     final Point p = ps.get( 0 );
-                    final Point p_new = new Point( value, p.getLatitude(), p.getLongitude(), p.getAltitude(), p
-                            .getAltiudeUnit() );
+                    final Point p_new = new Point( value,
+                                                   p.getLatitude(),
+                                                   p.getLongitude(),
+                                                   p.getAltitude(),
+                                                   p.getAltiudeUnit() );
                     ps.set( 0, p_new );
                 }
                 break;
@@ -937,8 +952,11 @@ class NodeEditPanel extends JPanel {
                 if ( !ForesterUtil.isEmpty( value ) ) {
                     final List<Point> ps = obtainPoints();
                     final Point p = ps.get( 0 );
-                    final Point p_new = new Point( p.getGeodeticDatum(), p.getLatitude(), p.getLongitude(), p
-                            .getAltitude(), value );
+                    final Point p_new = new Point( p.getGeodeticDatum(),
+                                                   p.getLatitude(),
+                                                   p.getLongitude(),
+                                                   p.getAltitude(),
+                                                   value );
                     ps.set( 0, p_new );
                 }
                 break;
@@ -962,8 +980,11 @@ class NodeEditPanel extends JPanel {
                 if ( new_value != null ) {
                     final List<Point> ps = obtainPoints();
                     final Point p = ps.get( 0 );
-                    final Point p_new = new Point( p.getGeodeticDatum(), p.getLatitude(), new_value, p.getAltitude(), p
-                            .getAltiudeUnit() );
+                    final Point p_new = new Point( p.getGeodeticDatum(),
+                                                   p.getLatitude(),
+                                                   new_value,
+                                                   p.getAltitude(),
+                                                   p.getAltiudeUnit() );
                     ps.set( 0, p_new );
                 }
                 break;
index 64236f4..2b37494 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index ff6e275..153d949 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -213,8 +213,9 @@ class NodePanel extends JPanel implements TreeSelectionListener {
         top.add( category );
         addSubelement( category, NODE_NAME, phylogeny_node.getName() );
         if ( phylogeny_node.getDistanceToParent() != PhylogenyNode.DISTANCE_DEFAULT ) {
-            addSubelement( category, NODE_BRANCH_LENGTH, ForesterUtil.FORMATTER_6.format( phylogeny_node
-                    .getDistanceToParent() ) );
+            addSubelement( category,
+                           NODE_BRANCH_LENGTH,
+                           ForesterUtil.FORMATTER_6.format( phylogeny_node.getDistanceToParent() ) );
         }
         if ( phylogeny_node.getBranchData().isHasConfidences() ) {
             for( final PhylogenyData conf : phylogeny_node.getBranchData().getConfidences() ) {
@@ -223,8 +224,9 @@ class NodePanel extends JPanel implements TreeSelectionListener {
         }
         if ( !phylogeny_node.isExternal() ) {
             addSubelement( category, "Children", String.valueOf( phylogeny_node.getNumberOfDescendants() ) );
-            addSubelement( category, "External children", String.valueOf( phylogeny_node.getAllExternalDescendants()
-                    .size() ) );
+            addSubelement( category,
+                           "External children",
+                           String.valueOf( phylogeny_node.getAllExternalDescendants().size() ) );
             final SortedMap<Taxonomy, Integer> distinct_tax = PhylogenyMethods
                     .obtainDistinctTaxonomyCounts( phylogeny_node );
             if ( distinct_tax != null ) {
index d0c6c92..babf160 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2009 Christian M. Zmasek
 // Copyright (C) 2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 5b524e9..af819de 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index bfc937d..0b99bf8 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -235,6 +235,7 @@ public class PhyloInferenceDialog extends JDialog implements ActionListener {
         setResizable( false );
     }
 
+    @Override
     public void actionPerformed( final ActionEvent e ) {
         if ( e.getSource() == _select_input_msa_btn ) {
             readInputFile();
index 3bd36d0..caf26f1 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 822c65f..613d883 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -161,23 +161,31 @@ public class PhylogeneticInferrer implements Runnable {
                 msa = inferMsa();
             }
             catch ( final IOException e ) {
-                JOptionPane.showMessageDialog( _mf, "Could not create multiple sequence alignment with "
-                        + _options.getMsaPrg() + "\nand the following parameters:\n\"" + _options.getMsaPrgParameters()
-                        + "\"\nError:" + e.getLocalizedMessage(), "Failed to Calculate MSA", JOptionPane.ERROR_MESSAGE );
+                JOptionPane.showMessageDialog( _mf,
+                                               "Could not create multiple sequence alignment with "
+                                                       + _options.getMsaPrg() + "\nand the following parameters:\n\""
+                                                       + _options.getMsaPrgParameters() + "\"\nError:"
+                                                       + e.getLocalizedMessage(),
+                                               "Failed to Calculate MSA",
+                                               JOptionPane.ERROR_MESSAGE );
                 return;
             }
             if ( msa == null ) {
-                JOptionPane.showMessageDialog( _mf, "Could not create multiple sequence alignment with "
-                        + _options.getMsaPrg() + "\nand the following parameters:\n\"" + _options.getMsaPrgParameters()
-                        + "\"", "Failed to Calculate MSA", JOptionPane.ERROR_MESSAGE );
+                JOptionPane.showMessageDialog( _mf,
+                                               "Could not create multiple sequence alignment with "
+                                                       + _options.getMsaPrg() + "\nand the following parameters:\n\""
+                                                       + _options.getMsaPrgParameters() + "\"",
+                                               "Failed to Calculate MSA",
+                                               JOptionPane.ERROR_MESSAGE );
                 return;
             }
             System.out.println( msa.toString() );
             System.out.println( MsaTools.calcBasicGapinessStatistics( msa ).toString() );
             final MsaTools msa_tools = MsaTools.createInstance();
             if ( _options.isExecuteMsaProcessing() ) {
-                msa = msa_tools.removeGapColumns( _options.getMsaProcessingMaxAllowedGapRatio(), _options
-                        .getMsaProcessingMinAllowedLength(), msa );
+                msa = msa_tools.removeGapColumns( _options.getMsaProcessingMaxAllowedGapRatio(),
+                                                  _options.getMsaProcessingMinAllowedLength(),
+                                                  msa );
                 if ( msa == null ) {
                     JOptionPane.showMessageDialog( _mf,
                                                    "Less than two sequences longer than "
@@ -235,13 +243,11 @@ public class PhylogeneticInferrer implements Runnable {
     private void writeToFiles( final BasicSymmetricalDistanceMatrix m ) {
         if ( !ForesterUtil.isEmpty( _options.getIntermediateFilesBase() ) ) {
             try {
-                final BufferedWriter msa_writer = new BufferedWriter( new FileWriter( _options
-                        .getIntermediateFilesBase()
+                final BufferedWriter msa_writer = new BufferedWriter( new FileWriter( _options.getIntermediateFilesBase()
                         + MSA_FILE_SUFFIX ) );
                 _msa.write( msa_writer );
                 msa_writer.close();
-                final BufferedWriter pwd_writer = new BufferedWriter( new FileWriter( _options
-                        .getIntermediateFilesBase()
+                final BufferedWriter pwd_writer = new BufferedWriter( new FileWriter( _options.getIntermediateFilesBase()
                         + PWD_FILE_SUFFIX ) );
                 m.write( pwd_writer );
                 pwd_writer.close();
index de5e41d..bca603e 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2009-2010 Christian M. Zmasek
 // Copyright (C) 2009-2010 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9277823..841f38c 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 54c6f80..c7edaa2 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -124,6 +124,7 @@ final class TextFrame extends JFrame implements ActionListener, ClipboardOwner {
         setVisible( true );
     }
 
+    @Override
     public void actionPerformed( final ActionEvent e ) {
         final Object o = e.getSource();
         if ( o == close_button ) {
@@ -149,6 +150,7 @@ final class TextFrame extends JFrame implements ActionListener, ClipboardOwner {
         sys_clipboard.setContents( contents, this );
     }
 
+    @Override
     public void lostOwnership( final Clipboard clipboard, final Transferable contents ) {
     }
 
index b99a27b..f822bf1 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2010 Burnham Institute for Medical Research
 // Copyright (C) 2003-2010 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 66020cc..29ae89c 100644 (file)
@@ -8,7 +8,7 @@
 // and Howard Hughes Medical Institute
 // Copyright (C) 2003-2007 Ethalinda K.S. Cannon
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -18,7 +18,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 7c40d10..c020b28 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -125,16 +125,11 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
     private static final float              HALF_PI                           = ( float ) ( Math.PI / 2.0 );
     private static final float              ANGLE_ROTATION_UNIT               = ( float ) ( Math.PI / 32 );
     private static final short              OV_BORDER                         = 10;
-    final static Cursor                     CUT_CURSOR                        = Cursor
-                                                                                      .getPredefinedCursor( Cursor.CROSSHAIR_CURSOR );
-    final static Cursor                     MOVE_CURSOR                       = Cursor
-                                                                                      .getPredefinedCursor( Cursor.MOVE_CURSOR );
-    final static Cursor                     ARROW_CURSOR                      = Cursor
-                                                                                      .getPredefinedCursor( Cursor.DEFAULT_CURSOR );
-    final static Cursor                     HAND_CURSOR                       = Cursor
-                                                                                      .getPredefinedCursor( Cursor.HAND_CURSOR );
-    final static Cursor                     WAIT_CURSOR                       = Cursor
-                                                                                      .getPredefinedCursor( Cursor.WAIT_CURSOR );
+    final static Cursor                     CUT_CURSOR                        = Cursor.getPredefinedCursor( Cursor.CROSSHAIR_CURSOR );
+    final static Cursor                     MOVE_CURSOR                       = Cursor.getPredefinedCursor( Cursor.MOVE_CURSOR );
+    final static Cursor                     ARROW_CURSOR                      = Cursor.getPredefinedCursor( Cursor.DEFAULT_CURSOR );
+    final static Cursor                     HAND_CURSOR                       = Cursor.getPredefinedCursor( Cursor.HAND_CURSOR );
+    final static Cursor                     WAIT_CURSOR                       = Cursor.getPredefinedCursor( Cursor.WAIT_CURSOR );
     private final static long               serialVersionUID                  = -978349745916505029L;
     private final static int                EURO_D                            = 10;
     private final static String             NODE_POPMENU_NODE_CLIENT_PROPERTY = "node";
@@ -222,8 +217,7 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
     private JTextArea                       _rollover_popup;
     //private final short                     _skip_counter                     = 0;
     private final StringBuffer              _popup_buffer                     = new StringBuffer();
-    final private static Font               POPUP_FONT                        = new Font( Configuration
-                                                                                                  .getDefaultFontFamilyName(),
+    final private static Font               POPUP_FONT                        = new Font( Configuration.getDefaultFontFamilyName(),
                                                                                           Font.PLAIN,
                                                                                           12 );
     private static final boolean            DRAW_MEAN_COUNTS                  = true;                                                     //TODO remove me later
@@ -2138,8 +2132,11 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
             final double r2 = 2.0 * parent_radius;
             drawArc( root_x - parent_radius, root_y - parent_radius, r2, r2, ( -angle - arc ), arc, g );
         }
-        drawLine( c.getXcoord(), c.getYcoord(), root_x + ( Math.cos( angle ) * parent_radius ), root_y
-                + ( Math.sin( angle ) * parent_radius ), g );
+        drawLine( c.getXcoord(),
+                  c.getYcoord(),
+                  root_x + ( Math.cos( angle ) * parent_radius ),
+                  root_y + ( Math.sin( angle ) * parent_radius ),
+                  g );
         paintNodeBox( c.getXcoord(), c.getYcoord(), c, g, to_pdf, to_graphics_file, isInFoundNodes( c ) );
         if ( c.isExternal() ) {
             final boolean is_in_found_nodes = isInFoundNodes( c );
@@ -2164,8 +2161,11 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
             final double r2 = 2.0 * parent_radius;
             drawArc( root_x - parent_radius, root_y - parent_radius, r2, r2, ( -angle - arc ), arc, g );
         }
-        drawLine( c.getXSecondary(), c.getYSecondary(), root_x + ( Math.cos( angle ) * parent_radius ), root_y
-                + ( Math.sin( angle ) * parent_radius ), g );
+        drawLine( c.getXSecondary(),
+                  c.getYSecondary(),
+                  root_x + ( Math.cos( angle ) * parent_radius ),
+                  root_y + ( Math.sin( angle ) * parent_radius ),
+                  g );
         if ( isInFoundNodes( c ) ) {
             g.setColor( getTreeColorSet().getFoundColor() );
             drawRectFilled( c.getXSecondary() - 1, c.getYSecondary() - 1, 3, 3, g );
@@ -2186,13 +2186,11 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
         if ( !node.isRoot() ) {
             if ( getPhylogenyGraphicsType() == PHYLOGENY_GRAPHICS_TYPE.EURO_STYLE ) {
                 TreePanel.drawString( FORMATTER_BRANCH_LENGTH.format( node.getDistanceToParent() ), node.getParent()
-                        .getXcoord()
-                        + EURO_D, node.getYcoord() - getTreeFontSet()._small_max_descent, g );
+                        .getXcoord() + EURO_D, node.getYcoord() - getTreeFontSet()._small_max_descent, g );
             }
             else if ( getPhylogenyGraphicsType() == PHYLOGENY_GRAPHICS_TYPE.ROUNDED ) {
                 TreePanel.drawString( FORMATTER_BRANCH_LENGTH.format( node.getDistanceToParent() ), node.getParent()
-                        .getXcoord()
-                        + ROUNDED_D, node.getYcoord() - getTreeFontSet()._small_max_descent, g );
+                        .getXcoord() + ROUNDED_D, node.getYcoord() - getTreeFontSet()._small_max_descent, g );
             }
             else {
                 TreePanel.drawString( FORMATTER_BRANCH_LENGTH.format( node.getDistanceToParent() ), node.getParent()
@@ -2277,8 +2275,7 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
                 boolean draw_vertical = true;
                 final PhylogenyNode parent = node.getParent();
                 if ( ( ( getOptions().isShowNodeBoxes() && !to_pdf && !to_graphics_file ) || ( ( getControlPanel()
-                        .isEvents() )
-                        && ( parent != null ) && parent.isHasAssignedEvent() ) )
+                        .isEvents() ) && ( parent != null ) && parent.isHasAssignedEvent() ) )
                         && ( _phylogeny.isRooted() || !( ( parent != null ) && parent.isRoot() ) )
                         && !( ( to_pdf || to_graphics_file ) && getOptions().isPrintBlackAndWhite() && !parent
                                 .isDuplication() ) ) {
@@ -2561,12 +2558,12 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
             d = BOX_SIZE;
         }
         _polygon.reset();
-        _polygon.addPoint( ForesterUtil.roundToInt( node.getXcoord() - TreePanel.BOX_SIZE ), ForesterUtil
-                .roundToInt( node.getYcoord() ) );
-        _polygon.addPoint( ForesterUtil.roundToInt( node.getXcoord() + TreePanel.BOX_SIZE ), ForesterUtil
-                .roundToInt( node.getYcoord() - d ) );
-        _polygon.addPoint( ForesterUtil.roundToInt( node.getXcoord() + TreePanel.BOX_SIZE ), ForesterUtil
-                .roundToInt( node.getYcoord() + d ) );
+        _polygon.addPoint( ForesterUtil.roundToInt( node.getXcoord() - TreePanel.BOX_SIZE ),
+                           ForesterUtil.roundToInt( node.getYcoord() ) );
+        _polygon.addPoint( ForesterUtil.roundToInt( node.getXcoord() + TreePanel.BOX_SIZE ),
+                           ForesterUtil.roundToInt( node.getYcoord() - d ) );
+        _polygon.addPoint( ForesterUtil.roundToInt( node.getXcoord() + TreePanel.BOX_SIZE ),
+                           ForesterUtil.roundToInt( node.getYcoord() + d ) );
         g.fillPolygon( _polygon );
         paintNodeData( g, node, to_graphics_file, to_pdf, is_in_found_nodes );
     }
@@ -2649,9 +2646,11 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
                 g.setColor( getTreeColorSet().getConfidenceColor() );
             }
             TreePanel
-                    .drawString( conf_str, parent_x
-                            + ( ( x - parent_x - getTreeFontSet()._fm_small.stringWidth( conf_str ) ) / 2 ), ( node
-                            .getYcoord() + getTreeFontSet()._small_max_ascent ) - 1, g );
+                    .drawString( conf_str,
+                                 parent_x
+                                         + ( ( x - parent_x - getTreeFontSet()._fm_small.stringWidth( conf_str ) ) / 2 ),
+                                 ( node.getYcoord() + getTreeFontSet()._small_max_ascent ) - 1,
+                                 g );
         }
     }
 
@@ -2673,9 +2672,10 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
                 g.setColor( Color.BLUE );
             }
             TreePanel
-                    .drawString( gained, parent_x
-                            + ( ( x - parent_x - getTreeFontSet()._fm_large.stringWidth( gained ) ) / 2 ), ( node
-                            .getYcoord() - getTreeFontSet()._fm_large.getMaxDescent() ), g );
+                    .drawString( gained,
+                                 parent_x + ( ( x - parent_x - getTreeFontSet()._fm_large.stringWidth( gained ) ) / 2 ),
+                                 ( node.getYcoord() - getTreeFontSet()._fm_large.getMaxDescent() ),
+                                 g );
             g.setColor( getTreeColorSet().getLostCharactersColor() );
             TreePanel.drawString( lost,
                                   parent_x + ( ( x - parent_x - getTreeFontSet()._fm_large.stringWidth( lost ) ) / 2 ),
@@ -2772,8 +2772,7 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
             x += drawTaxonomyImage( node.getXcoord() + 2 + TreePanel.HALF_BOX_SIZE, node.getYcoord(), node, g );
         }
         if ( ( getControlPanel().isShowTaxonomyCode() || getControlPanel().isShowTaxonomyScientificNames() || getControlPanel()
-                .isShowTaxonomyCommonNames() )
-                && node.getNodeData().isHasTaxonomy() ) {
+                .isShowTaxonomyCommonNames() ) && node.getNodeData().isHasTaxonomy() ) {
             x += paintTaxonomy( g, node, is_in_found_nodes, to_pdf, to_graphics_file, x );
         }
         if ( ( to_pdf || to_graphics_file ) && getOptions().isPrintBlackAndWhite() ) {
@@ -2967,10 +2966,11 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
                                 + ( getTreeFontSet()._fm_large.getAscent() / down_shift_factor ), g );
                     }
                     else {
-                        TreePanel.drawString( " " + node.getNodeData().getBinaryCharacters().getPresentCount(), node
-                                .getXcoord()
-                                + x + 4 + TreePanel.HALF_BOX_SIZE, node.getYcoord()
-                                + ( getTreeFontSet()._fm_large.getAscent() / down_shift_factor ), g );
+                        TreePanel.drawString( " " + node.getNodeData().getBinaryCharacters().getPresentCount(),
+                                              node.getXcoord() + x + 4 + TreePanel.HALF_BOX_SIZE,
+                                              node.getYcoord()
+                                                      + ( getTreeFontSet()._fm_large.getAscent() / down_shift_factor ),
+                                              g );
                     }
                     paintGainedAndLostCharacters( g, node, "+"
                             + node.getNodeData().getBinaryCharacters().getGainedCount(), "-"
@@ -3006,8 +3006,16 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
                         final int x_w = ( int ) ( x + ws + 0.5 );
                         final int y_h = ( int ) ( my_y + hs + 0.5 );
                         if ( ( x_w - x > 7 ) && ( y_h - my_y > 7 ) ) {
-                            g.drawImage( bi, ( int ) ( x + 0.5 + offset ), ( int ) ( my_y + 0.5 ), x_w, y_h, 0, 0, bi
-                                    .getWidth(), bi.getHeight(), null );
+                            g.drawImage( bi,
+                                         ( int ) ( x + 0.5 + offset ),
+                                         ( int ) ( my_y + 0.5 ),
+                                         x_w,
+                                         y_h,
+                                         0,
+                                         0,
+                                         bi.getWidth(),
+                                         bi.getHeight(),
+                                         null );
                             ws += 8;
                         }
                         else {
@@ -4488,9 +4496,10 @@ public final class TreePanel extends JPanel implements ActionListener, MouseWhee
                             _popup_buffer.append( confidence.getType() );
                             _popup_buffer.append( "] " );
                         }
-                        _popup_buffer.append( FORMATTER_CONFIDENCE.format( ForesterUtil
-                                .round( confidence.getValue(), getOptions()
-                                        .getNumberOfDigitsAfterCommaForConfidenceValues() ) ) );
+                        _popup_buffer
+                                .append( FORMATTER_CONFIDENCE.format( ForesterUtil.round( confidence.getValue(),
+                                                                                          getOptions()
+                                                                                                  .getNumberOfDigitsAfterCommaForConfidenceValues() ) ) );
                     }
                 }
                 if ( _popup_buffer.length() > 0 ) {
index 729d569..002adad 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -147,14 +147,16 @@ public class UrlTreeReader implements Runnable {
                                                JOptionPane.ERROR_MESSAGE );
             }
             catch ( final IOException e ) {
-                JOptionPane.showMessageDialog( _main_frame, "Could not read from " + url + "\n"
-                        + e.getLocalizedMessage(), "Failed to read tree from " + client.getName() + " for "
-                        + identifier, JOptionPane.ERROR_MESSAGE );
+                JOptionPane.showMessageDialog( _main_frame,
+                                               "Could not read from " + url + "\n" + e.getLocalizedMessage(),
+                                               "Failed to read tree from " + client.getName() + " for " + identifier,
+                                               JOptionPane.ERROR_MESSAGE );
             }
             catch ( final NumberFormatException e ) {
-                JOptionPane.showMessageDialog( _main_frame, "Could not read from " + url + "\n"
-                        + e.getLocalizedMessage(), "Failed to read tree from " + client.getName() + " for "
-                        + identifier, JOptionPane.ERROR_MESSAGE );
+                JOptionPane.showMessageDialog( _main_frame,
+                                               "Could not read from " + url + "\n" + e.getLocalizedMessage(),
+                                               "Failed to read tree from " + client.getName() + " for " + identifier,
+                                               JOptionPane.ERROR_MESSAGE );
             }
             catch ( final Exception e ) {
                 e.printStackTrace();
index 3f7a50e..d347ab1 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -116,8 +116,8 @@ final class Util {
                         }
                         String suffix = "";
                         if ( my_name_for_file.indexOf( '.' ) > 0 ) {
-                            suffix = my_name_for_file.substring( my_name_for_file.lastIndexOf( '.' ), my_name_for_file
-                                    .length() );
+                            suffix = my_name_for_file.substring( my_name_for_file.lastIndexOf( '.' ),
+                                                                 my_name_for_file.length() );
                             my_name_for_file = my_name_for_file.substring( 0, my_name_for_file.lastIndexOf( '.' ) );
                         }
                         if ( !ForesterUtil.isEmpty( my_name_for_file ) ) {
@@ -300,8 +300,8 @@ final class Util {
                     n.getBranchData().setBranchColor( new BranchColor( tree_panel.calculateTaxonomyBasedColor( tax ) ) );
                     final List<PhylogenyNode> descs = PhylogenyMethods.getAllDescendants( n );
                     for( final PhylogenyNode desc : descs ) {
-                        desc.getBranchData().setBranchColor( new BranchColor( tree_panel
-                                .calculateTaxonomyBasedColor( tax ) ) );
+                        desc.getBranchData()
+                                .setBranchColor( new BranchColor( tree_panel.calculateTaxonomyBasedColor( tax ) ) );
                     }
                 }
             }
index ae18572..4db567e 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index df45fe5..ed12a91 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -144,10 +144,12 @@ public final class RenderableDomainArchitecture extends DomainArchitecture imple
         return _domain_structure.getNumberOfDomains();
     }
 
+    @Override
     public Dimension getOriginalSize() {
         return new Dimension( _domain_structure.getTotalLength(), ForesterUtil.roundToInt( _rendering_height ) );
     }
 
+    @Override
     public Object getParameter() {
         return new Integer( _e_value_threshold_exp );
     }
@@ -156,6 +158,7 @@ public final class RenderableDomainArchitecture extends DomainArchitecture imple
         return _rendering_factor_width;
     }
 
+    @Override
     public Dimension getRenderingSize() {
         return new Dimension( ForesterUtil.roundToInt( _domain_structure.getTotalLength() * _rendering_factor_width ),
                               ForesterUtil.roundToInt( _rendering_height ) );
@@ -171,6 +174,7 @@ public final class RenderableDomainArchitecture extends DomainArchitecture imple
         return _domain_structure.isEqual( data );
     }
 
+    @Override
     public void render( final double x1,
                         final double y1,
                         final Graphics2D g,
@@ -198,6 +202,7 @@ public final class RenderableDomainArchitecture extends DomainArchitecture imple
         }
     }
 
+    @Override
     public void setParameter( final double e_value_threshold_exp ) {
         _e_value_threshold_exp = ( int ) e_value_threshold_exp;
     }
@@ -206,6 +211,7 @@ public final class RenderableDomainArchitecture extends DomainArchitecture imple
         _rendering_factor_width = rendering_factor_width;
     }
 
+    @Override
     public void setRenderingHeight( final double rendering_height ) {
         _rendering_height = rendering_height;
     }
index 1755671..b4f3868 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index c22b645..2785daf 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -102,6 +102,7 @@ public final class RenderableVector implements RenderablePhylogenyData {
         throw new NoSuchMethodError();
     }
 
+    @Override
     public void render( final double x1,
                         final double y1,
                         final Graphics2D g,
index 3e613e2..f970c64 100644 (file)
@@ -5,7 +5,7 @@
 //
 // Copyright (C) 2008-2010 Christian M. Zmasek
 // Copyright (C) 2008-2010 Burnham Institute for Medical Research
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index f8e833e..100bc22 100644 (file)
@@ -4,7 +4,7 @@
 //
 // Copyright (C) 2008-2010 Christian M. Zmasek
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -14,7 +14,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9ca03a1..1918587 100644 (file)
@@ -4,7 +4,7 @@
 //
 // Copyright (C) 2008-2010 Christian M. Zmasek
 // Copyright (C) 2008-2010 Burnham Institute for Medical Research
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -14,7 +14,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -54,69 +54,64 @@ public final class WebserviceUtil {
 
     public static List<PhylogeniesWebserviceClient> createDefaultClients() {
         final List<PhylogeniesWebserviceClient> clients = new ArrayList<PhylogeniesWebserviceClient>();
-        clients
-                .add( new BasicPhylogeniesWebserviceClient( TOL_NAME,
-                                                            "Read Tree from Tree of Life...",
-                                                            "Use ToL webservice to obtain a phylogeny",
-                                                            "Please enter a Tree of Life node identifier\n(Examples: "
-                                                                    + "19386 for Cephalopoda, 2461 for Cnidaria, 2466 for Deuterostomia)",
-                                                            WsPhylogenyFormat.TOL_XML_RESPONSE,
-                                                            PhylogenyNodeField.TAXONOMY_SCIENTIFIC_NAME,
-                                                            WebserviceUtil.TOL_WEBSERVER,
-                                                            true,
-                                                            "http://tolweb.org",
-                                                            null ) );
-        clients
-                .add( new BasicPhylogeniesWebserviceClient( TREE_BASE_NAME,
-                                                            "Read Tree from TreeBASE...",
-                                                            "Use TreeBASE to obtain a phylogeny",
-                                                            "Please enter a TreeBASE tree identifier\n(Examples: 2654, 825, 4931, 2518, 2406, 4934)",
-                                                            WsPhylogenyFormat.NEXUS,
-                                                            PhylogenyNodeField.TAXONOMY_SCIENTIFIC_NAME,
-                                                            "http://purl.org/phylo/treebase/phylows/tree/TB2:Tr"
-                                                                    + PhylogeniesWebserviceClient.QUERY_PLACEHOLDER
-                                                                    + "?format=nexus",
-                                                            true,
-                                                            "http://treebase.nescent.org",
-                                                            null ) );
-        clients
-                .add( new BasicPhylogeniesWebserviceClient( PFAM_NAME,
-                                                            "Read Gene Tree from Pfam...",
-                                                            "Use  Pfam to obtain a (full) gene tree",
-                                                            "Please enter a Pfam (PF) accession number\n(Examples: 01849 for NAC, 00452 for Bcl-2, 00046 for Homeobox)",
-                                                            WsPhylogenyFormat.PFAM,
-                                                            null,
-                                                            PFAM_SERVER + "/family/tree/download?alnType=full&acc=PF"
-                                                                    + PhylogeniesWebserviceClient.QUERY_PLACEHOLDER,
-                                                            false,
-                                                            PFAM_SERVER,
-                                                            PFAM_INST ) );
-        clients
-                .add( new BasicPhylogeniesWebserviceClient( TREE_FAM_NAME,
-                                                            "Read Full Gene Tree from TreeFam...",
-                                                            "Use TreeFam to obtain a (full) gene tree",
-                                                            "Please enter a TreeFam (TF) accession number\n(Examples: 101004 for Cyclin D, 315938 for Hox, 105310 for Wnt)",
-                                                            WsPhylogenyFormat.NHX,
-                                                            null,
-                                                            "http://www.treefam.org/cgi-bin/getdata.pl?ac=TF"
-                                                                    + PhylogeniesWebserviceClient.QUERY_PLACEHOLDER
-                                                                    + "&f=full.nhx",
-                                                            true,
-                                                            "http://www.treefam.org",
-                                                            TREE_FAM_INST ) );
-        clients
-                .add( new BasicPhylogeniesWebserviceClient( TREE_FAM_NAME,
-                                                            "Read Clean Gene Tree from TreeFam...",
-                                                            "Use TreeFam to obtain a (\"clean\") gene tree",
-                                                            "Please enter a TreeFam (TF) accession number\n(Examples: 101004 for Cyclin D, 315938 for Hox, 105310 for Wnt)",
-                                                            WsPhylogenyFormat.NHX,
-                                                            null,
-                                                            "http://www.treefam.org/cgi-bin/getdata.pl?ac=TF"
-                                                                    + PhylogeniesWebserviceClient.QUERY_PLACEHOLDER
-                                                                    + "&f=clean.nhx",
-                                                            true,
-                                                            "http://www.treefam.org",
-                                                            TREE_FAM_INST ) );
+        clients.add( new BasicPhylogeniesWebserviceClient( TOL_NAME,
+                                                           "Read Tree from Tree of Life...",
+                                                           "Use ToL webservice to obtain a phylogeny",
+                                                           "Please enter a Tree of Life node identifier\n(Examples: "
+                                                                   + "19386 for Cephalopoda, 2461 for Cnidaria, 2466 for Deuterostomia)",
+                                                           WsPhylogenyFormat.TOL_XML_RESPONSE,
+                                                           PhylogenyNodeField.TAXONOMY_SCIENTIFIC_NAME,
+                                                           WebserviceUtil.TOL_WEBSERVER,
+                                                           true,
+                                                           "http://tolweb.org",
+                                                           null ) );
+        clients.add( new BasicPhylogeniesWebserviceClient( TREE_BASE_NAME,
+                                                           "Read Tree from TreeBASE...",
+                                                           "Use TreeBASE to obtain a phylogeny",
+                                                           "Please enter a TreeBASE tree identifier\n(Examples: 2654, 825, 4931, 2518, 2406, 4934)",
+                                                           WsPhylogenyFormat.NEXUS,
+                                                           PhylogenyNodeField.TAXONOMY_SCIENTIFIC_NAME,
+                                                           "http://purl.org/phylo/treebase/phylows/tree/TB2:Tr"
+                                                                   + PhylogeniesWebserviceClient.QUERY_PLACEHOLDER
+                                                                   + "?format=nexus",
+                                                           true,
+                                                           "http://treebase.nescent.org",
+                                                           null ) );
+        clients.add( new BasicPhylogeniesWebserviceClient( PFAM_NAME,
+                                                           "Read Gene Tree from Pfam...",
+                                                           "Use  Pfam to obtain a (full) gene tree",
+                                                           "Please enter a Pfam (PF) accession number\n(Examples: 01849 for NAC, 00452 for Bcl-2, 00046 for Homeobox)",
+                                                           WsPhylogenyFormat.PFAM,
+                                                           null,
+                                                           PFAM_SERVER + "/family/tree/download?alnType=full&acc=PF"
+                                                                   + PhylogeniesWebserviceClient.QUERY_PLACEHOLDER,
+                                                           false,
+                                                           PFAM_SERVER,
+                                                           PFAM_INST ) );
+        clients.add( new BasicPhylogeniesWebserviceClient( TREE_FAM_NAME,
+                                                           "Read Full Gene Tree from TreeFam...",
+                                                           "Use TreeFam to obtain a (full) gene tree",
+                                                           "Please enter a TreeFam (TF) accession number\n(Examples: 101004 for Cyclin D, 315938 for Hox, 105310 for Wnt)",
+                                                           WsPhylogenyFormat.NHX,
+                                                           null,
+                                                           "http://www.treefam.org/cgi-bin/getdata.pl?ac=TF"
+                                                                   + PhylogeniesWebserviceClient.QUERY_PLACEHOLDER
+                                                                   + "&f=full.nhx",
+                                                           true,
+                                                           "http://www.treefam.org",
+                                                           TREE_FAM_INST ) );
+        clients.add( new BasicPhylogeniesWebserviceClient( TREE_FAM_NAME,
+                                                           "Read Clean Gene Tree from TreeFam...",
+                                                           "Use TreeFam to obtain a (\"clean\") gene tree",
+                                                           "Please enter a TreeFam (TF) accession number\n(Examples: 101004 for Cyclin D, 315938 for Hox, 105310 for Wnt)",
+                                                           WsPhylogenyFormat.NHX,
+                                                           null,
+                                                           "http://www.treefam.org/cgi-bin/getdata.pl?ac=TF"
+                                                                   + PhylogeniesWebserviceClient.QUERY_PLACEHOLDER
+                                                                   + "&f=clean.nhx",
+                                                           true,
+                                                           "http://www.treefam.org",
+                                                           TREE_FAM_INST ) );
         return clients;
     }
 
@@ -160,8 +155,9 @@ public final class WebserviceUtil {
         while ( it.hasNext() ) {
             final PhylogenyNode n = it.next();
             if ( n.getNodeData().isHasTaxonomy() && ( n.getNodeData().getTaxonomy().getIdentifier() != null ) ) {
-                n.getNodeData().getTaxonomy().setIdentifier( new Identifier( n.getNodeData().getTaxonomy()
-                        .getIdentifier().getValue(), type ) );
+                n.getNodeData()
+                        .getTaxonomy()
+                        .setIdentifier( new Identifier( n.getNodeData().getTaxonomy().getIdentifier().getValue(), type ) );
             }
         }
     }
index 181439b..95e03c2 100644 (file)
@@ -4,7 +4,7 @@
 //
 // Copyright (C) 2008-2010 Christian M. Zmasek
 // Copyright (C) 2008-2010 Burnham Institute for Medical Research
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -14,7 +14,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 77240a6..c0c9c21 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index dbea137..645735b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d41194a..9cb5e77 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d9e23c9..b77aa23 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6ee7715..4ad1323 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index da8088c..1d02267 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 5011938..a88d8f2 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 5849ac1..7726735 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 13f99e8..29474c4 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 544ac02..961c13a 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6ecfb11..30b5f9b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -99,6 +99,7 @@ public class BasicCharacterStateMatrix<S> implements CharacterStateMatrix<S> {
         return _identifier_index_map.containsKey( identifier );
     }
 
+    @Override
     public CharacterStateMatrix<S> copy() {
         final CharacterStateMatrix<S> new_matrix = new BasicCharacterStateMatrix<S>( getNumberOfIdentifiers(),
                                                                                      getNumberOfCharacters() );
@@ -243,6 +244,7 @@ public class BasicCharacterStateMatrix<S> implements CharacterStateMatrix<S> {
         return getNumberOfIdentifiers() <= 0;
     }
 
+    @Override
     public CharacterStateMatrix<S> pivot() {
         final CharacterStateMatrix<S> new_matrix = new BasicCharacterStateMatrix<S>( getNumberOfCharacters(),
                                                                                      getNumberOfIdentifiers() );
@@ -397,6 +399,7 @@ public class BasicCharacterStateMatrix<S> implements CharacterStateMatrix<S> {
     //to format for microarray-style clustering
     // states are ints in this case
     //TODO
+    @Override
     public void toWriter( final Writer writer ) throws IOException {
         toForester( writer );
     }
index 5467341..905552c 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9094d18..a05e93d 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index ac17854..85f9184 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -47,10 +47,12 @@ public class BasicSymmetricalDistanceMatrix implements DistanceMatrix {
         _identifiers = new String[ size ];
     }
 
+    @Override
     public String getIdentifier( final int i ) {
         return _identifiers[ i ];
     }
 
+    @Override
     public int getIndex( final String identifier ) {
         for( int i = 0; i < _identifiers.length; i++ ) {
             if ( getIdentifier( i ).equals( identifier ) ) {
@@ -60,10 +62,12 @@ public class BasicSymmetricalDistanceMatrix implements DistanceMatrix {
         throw new IllegalArgumentException( "identifier [" + identifier + "] not found in distance matrix" );
     }
 
+    @Override
     public int getSize() {
         return _values.length;
     }
 
+    @Override
     public double getValue( final int col, final int row ) {
         if ( col == row ) {
             if ( col >= getSize() ) {
@@ -86,6 +90,7 @@ public class BasicSymmetricalDistanceMatrix implements DistanceMatrix {
         }
     }
 
+    @Override
     public void setIdentifier( final int i, final String identifier ) {
         _identifiers[ i ] = identifier;
     }
@@ -99,6 +104,7 @@ public class BasicSymmetricalDistanceMatrix implements DistanceMatrix {
         }
     }
 
+    @Override
     public void setValue( final int col, final int row, final double d ) {
         if ( ( col == row ) && ( d != 0.0 ) ) {
             throw new IllegalArgumentException( "attempt to set a non-zero value on the diagonal of a symmetrical distance matrix" );
@@ -172,6 +178,7 @@ public class BasicSymmetricalDistanceMatrix implements DistanceMatrix {
         return toPhylip().toString();
     }
 
+    @Override
     public StringBuffer toStringBuffer( final Format format ) {
         switch ( format ) {
             case PHYLIP:
index 74f8ff1..1a42fd3 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index a10e865..65c072c 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -130,8 +130,7 @@ public class DolloParsimony {
     private Map<PhylogenyNode, BinaryStates> getStatesForCharacter( final Phylogeny p,
                                                                     final CharacterStateMatrix<BinaryStates> matrix,
                                                                     final int character_index ) {
-        final Map<PhylogenyNode, BinaryStates> states = new HashMap<PhylogenyNode, BinaryStates>( matrix
-                .getNumberOfIdentifiers() );
+        final Map<PhylogenyNode, BinaryStates> states = new HashMap<PhylogenyNode, BinaryStates>( matrix.getNumberOfIdentifiers() );
         for( int indentifier_index = 0; indentifier_index < matrix.getNumberOfIdentifiers(); ++indentifier_index ) {
             final BinaryStates state = matrix.getState( indentifier_index, character_index );
             if ( state == null ) {
index 8323167..9d9a602 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -213,8 +213,7 @@ public class FitchParsimony<STATE_TYPE> {
     private Map<PhylogenyNode, STATE_TYPE> getStatesForCharacterForTraceback( final Phylogeny p,
                                                                               final CharacterStateMatrix<STATE_TYPE> matrix,
                                                                               final int character_index ) {
-        final Map<PhylogenyNode, STATE_TYPE> states = new HashMap<PhylogenyNode, STATE_TYPE>( matrix
-                .getNumberOfIdentifiers() );
+        final Map<PhylogenyNode, STATE_TYPE> states = new HashMap<PhylogenyNode, STATE_TYPE>( matrix.getNumberOfIdentifiers() );
         for( int indentifier_index = 0; indentifier_index < matrix.getNumberOfIdentifiers(); ++indentifier_index ) {
             final STATE_TYPE state = matrix.getState( indentifier_index, character_index );
             if ( state == null ) {
@@ -308,8 +307,7 @@ public class FitchParsimony<STATE_TYPE> {
                                                              .getName() );
             getInternalStatesMatrixPriorToTraceback().setIdentifier( identifier_index,
                                                                      ForesterUtil.isEmpty( node.getName() ) ? node
-                                                                             .getId()
-                                                                             + "" : node.getName() );
+                                                                             .getId() + "" : node.getName() );
             ++identifier_index;
         }
         for( int character_index = 0; character_index < external_node_states_matrix.getNumberOfCharacters(); ++character_index ) {
@@ -416,7 +414,7 @@ public class FitchParsimony<STATE_TYPE> {
                 else if ( current_binary_state == ABSENT ) {//new
                     setGainLossState( character_state_column, current_node, UNCHANGED_ABSENT );//new
                 }//new
-                // setGainLossState( character_state_column, current_node, UNKNOWN_GAIN_LOSS );
+                 // setGainLossState( character_state_column, current_node, UNKNOWN_GAIN_LOSS );
             }
         }
     }
index 195a7e0..ecad514 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -220,8 +220,7 @@ public class SankoffParsimony<STATE_TYPE> {
     private Map<PhylogenyNode, STATE_TYPE> getStatesForCharacterForTraceback( final Phylogeny p,
                                                                               final CharacterStateMatrix<STATE_TYPE> matrix,
                                                                               final int character_index ) {
-        final Map<PhylogenyNode, STATE_TYPE> states = new HashMap<PhylogenyNode, STATE_TYPE>( matrix
-                .getNumberOfIdentifiers() );
+        final Map<PhylogenyNode, STATE_TYPE> states = new HashMap<PhylogenyNode, STATE_TYPE>( matrix.getNumberOfIdentifiers() );
         for( int indentifier_index = 0; indentifier_index < matrix.getNumberOfIdentifiers(); ++indentifier_index ) {
             final STATE_TYPE state = matrix.getState( indentifier_index, character_index );
             if ( state == null ) {
@@ -315,8 +314,7 @@ public class SankoffParsimony<STATE_TYPE> {
                                                              .getName() );
             getInternalStatesMatrixPriorToTraceback().setIdentifier( identifier_index,
                                                                      ForesterUtil.isEmpty( node.getName() ) ? node
-                                                                             .getId()
-                                                                             + "" : node.getName() );
+                                                                             .getId() + "" : node.getName() );
             ++identifier_index;
         }
         for( int character_index = 0; character_index < external_node_states_matrix.getNumberOfCharacters(); ++character_index ) {
@@ -423,7 +421,7 @@ public class SankoffParsimony<STATE_TYPE> {
                 else if ( current_binary_state == ABSENT ) {//new
                     setGainLossState( character_state_column, current_node, UNCHANGED_ABSENT );//new
                 }//new
-                // setGainLossState( character_state_column, current_node, UNKNOWN_GAIN_LOSS );
+                 // setGainLossState( character_state_column, current_node, UNKNOWN_GAIN_LOSS );
             }
         }
     }
index 123f77b..7837762 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6f8dd32..69d612f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -70,6 +70,7 @@ public class BasicGoRelationship implements GoRelationship {
         _go_id = go_id;
     }
 
+    @Override
     public int compareTo( final GoRelationship rel ) {
         return getGoId().compareTo( rel.getGoId() );
     }
@@ -97,10 +98,12 @@ public class BasicGoRelationship implements GoRelationship {
         }
     }
 
+    @Override
     public GoId getGoId() {
         return _go_id;
     }
 
+    @Override
     public Type getType() {
         return _type;
     }
index 19d20ed..de2f65f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -64,6 +64,7 @@ public class BasicGoSubset implements GoSubset {
         _type = type;
     }
 
+    @Override
     public int compareTo( final GoSubset sub ) {
         return getType().compareTo( sub.getType() );
     }
@@ -85,6 +86,7 @@ public class BasicGoSubset implements GoSubset {
         }
     }
 
+    @Override
     public Type getType() {
         return _type;
     }
index 768de1c..4401afe 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -69,10 +69,12 @@ public class BasicGoTerm implements GoTerm {
         init();
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         return new StringBuffer( getGoId().toString() );
     }
 
+    @Override
     public StringBuffer asText() {
         return new StringBuffer( toString() );
     }
@@ -81,6 +83,7 @@ public class BasicGoTerm implements GoTerm {
      * Compares based on GO id.
      * 
      */
+    @Override
     public int compareTo( final GoTerm go_term ) {
         return getGoId().compareTo( go_term.getGoId() );
     }
@@ -90,6 +93,7 @@ public class BasicGoTerm implements GoTerm {
      * 
      * 
      */
+    @Override
     public PhylogenyData copy() {
         final BasicGoTerm gt = new BasicGoTerm( getGoId(), getName(), getGoNameSpace(), isObsolete() );
         gt.setGoXrefs( getGoXRefs() );
@@ -121,6 +125,7 @@ public class BasicGoTerm implements GoTerm {
         }
     }
 
+    @Override
     public List<GoId> getAltIds() {
         return _alt_ids;
     }
@@ -135,10 +140,12 @@ public class BasicGoTerm implements GoTerm {
         return _definition;
     }
 
+    @Override
     public GoId getGoId() {
         return _id;
     }
 
+    @Override
     public GoNameSpace getGoNameSpace() {
         return _namespace;
     }
@@ -153,14 +160,17 @@ public class BasicGoTerm implements GoTerm {
         return _go_subsets;
     }
 
+    @Override
     public List<GoXRef> getGoXRefs() {
         return _go_xrefs;
     }
 
+    @Override
     public String getName() {
         return _name;
     }
 
+    @Override
     public List<GoId> getSuperGoIds() {
         return _super_go_ids;
     }
@@ -185,10 +195,12 @@ public class BasicGoTerm implements GoTerm {
         setComment( "" );
     }
 
+    @Override
     public boolean isEqual( final PhylogenyData go_term ) {
         return equals( go_term );
     }
 
+    @Override
     public boolean isObsolete() {
         return _is_obsolete;
     }
@@ -221,10 +233,12 @@ public class BasicGoTerm implements GoTerm {
         _super_go_ids = super_terms;
     }
 
+    @Override
     public StringBuffer toNHX() {
         throw new UnsupportedOperationException();
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         throw new UnsupportedOperationException();
     }
index 8d5b4ae..3ce65b3 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -92,6 +92,7 @@ public class BasicGoXRef implements GoXRef {
         _xref = xref;
     }
 
+    @Override
     public int compareTo( final GoXRef xref ) {
         return getXRef().compareTo( xref.getXRef() );
     }
@@ -117,6 +118,7 @@ public class BasicGoXRef implements GoXRef {
         }
     }
 
+    @Override
     public Type getType() {
         return _type;
     }
index 3ba3fe5..cc02247 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -47,6 +47,7 @@ public class GoId implements Comparable<GoId> {
         _id = id.substring( 3 );
     }
 
+    @Override
     public int compareTo( final GoId id ) {
         return getId().compareTo( id.getId() );
     }
index fa76552..c9dc103 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d7f5e79..2d308ba 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index c963217..620b15f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 7068ab6..600cb41 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 680489a..39a778f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index fe96c4b..adab829 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9a2fbb5..440094f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b79e172..b47a60b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 93ee62a..0e6717c 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 4fdcd29..ab66c36 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -212,8 +212,7 @@ public class TestGo {
             if ( !g0.getComment().equals( "" ) ) {
                 return false;
             }
-            if ( !g0
-                    .getDefinition()
+            if ( !g0.getDefinition()
                     .equals( "\"The distribution of mitochondria, including the mitochondrial genome, into daughter cells after mitosis or meiosis, mediated by interactions between mitochondria and the cytoskeleton.\" [GOC:mcc, PMID:10873824, PMID:11389764]" ) ) {
                 return false;
             }
@@ -244,8 +243,7 @@ public class TestGo {
             if ( !g1.getComment().equals( "comment" ) ) {
                 return false;
             }
-            if ( !g1
-                    .getDefinition()
+            if ( !g1.getDefinition()
                     .equals( "\"The maintenance of the structure and integrity of the mitochondrial genome.\" [GOC:ai]" ) ) {
                 return false;
             }
index 970f939..10ac1fd 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -438,22 +438,18 @@ public class MetaOntologizer {
         w.write( ForesterUtil.LINE_SEPARATOR );
         w.write( "a.new_type:link { font-size: 7pt; color : #505050; text-decoration : none; }" );
         w.write( ForesterUtil.LINE_SEPARATOR );
-        w
-                .write( "a.new_type:hover { font-size: 7pt; color : #000000; background-color : #FFFF00; text-decoration : none; }" );
+        w.write( "a.new_type:hover { font-size: 7pt; color : #000000; background-color : #FFFF00; text-decoration : none; }" );
         w.write( ForesterUtil.LINE_SEPARATOR );
-        w
-                .write( "a.new_type:hover { font-size: 7pt; color : #000000; background-color : #FFFF00; text-decoration : none; }" );
+        w.write( "a.new_type:hover { font-size: 7pt; color : #000000; background-color : #FFFF00; text-decoration : none; }" );
         w.write( ForesterUtil.LINE_SEPARATOR );
         w.write( "td { text-align: left; vertical-align: top; font-family: Verdana, Arial, Helvetica; font-size: 8pt}" );
         w.write( ForesterUtil.LINE_SEPARATOR );
-        w
-                .write( "th { text-align: left; vertical-align: top; font-family: Verdana, Arial, Helvetica; font-size: 10pt; font-weight: bold }" );
+        w.write( "th { text-align: left; vertical-align: top; font-family: Verdana, Arial, Helvetica; font-size: 10pt; font-weight: bold }" );
         w.write( ForesterUtil.LINE_SEPARATOR );
         w.write( "h1 { color : #000000; font-family: Verdana, Arial, Helvetica; font-size: 18pt; font-weight: bold }" );
         w.write( ForesterUtil.LINE_SEPARATOR );
         w.write( "h2 { color : #000000; font-family: Verdana, Arial, Helvetica; font-size: 16pt; font-weight: bold }" );
-        w
-                .write( "h3 { margin-top: 12px;  margin-bottom: 0px; color : #000000; font-family: Verdana, Arial, Helvetica; font-size: 12pt; font-weight: bold }" );
+        w.write( "h3 { margin-top: 12px;  margin-bottom: 0px; color : #000000; font-family: Verdana, Arial, Helvetica; font-size: 12pt; font-weight: bold }" );
         w.write( ForesterUtil.LINE_SEPARATOR );
         w.write( "</style>" );
         w.write( ForesterUtil.LINE_SEPARATOR );
@@ -592,8 +588,11 @@ public class MetaOntologizer {
         writer.write( String.valueOf( ontologizer_result.getStudyTerm() ) );
         writer.write( "</td><td>" );
         if ( domains_per_species != null ) {
-            final StringBuilder sb = obtainDomainsForGoId( pfam_to_go, domains_per_species, go_id_to_terms, go_term
-                    .getGoId(), domain_ids_with_go_annot );
+            final StringBuilder sb = obtainDomainsForGoId( pfam_to_go,
+                                                           domains_per_species,
+                                                           go_id_to_terms,
+                                                           go_term.getGoId(),
+                                                           domain_ids_with_go_annot );
             writer.write( sb.toString() );
         }
         else {
index d7e2be5..47751e8 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 4c6845c..b04e254 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -144,8 +144,8 @@ public class FastaParser {
         reader.close();
         final List<Sequence> seqs = new ArrayList<Sequence>();
         for( int i = 0; i < temp_msa.size(); ++i ) {
-            seqs.add( BasicSequence.createAaSequence( temp_msa.get( i )[ 0 ].toString(), temp_msa.get( i )[ 1 ]
-                    .toString() ) );
+            seqs.add( BasicSequence.createAaSequence( temp_msa.get( i )[ 0 ].toString(),
+                                                      temp_msa.get( i )[ 1 ].toString() ) );
         }
         return seqs;
     }
index 4b7e920..6e79477 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 42f94ee..15d164a 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index a63ba50..ac6a2bc 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d319d96..d4bbdb4 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b9df246..991329b 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 5d0ed60..7962717 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 67512d7..4c4f67b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 7e20bee..cbc15db 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 879a0e1..4279ade 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -139,6 +139,7 @@ public class NexusPhylogeniesParser implements PhylogenyParser {
         return _replace_underscores;
     }
 
+    @Override
     public Phylogeny[] parse() throws IOException, NHXFormatException {
         reset();
         final BufferedReader reader = ParserUtils.createReader( getNexusSource() );
@@ -287,6 +288,7 @@ public class NexusPhylogeniesParser implements PhylogenyParser {
         _replace_underscores = replace_underscores;
     }
 
+    @Override
     public void setSource( final Object nexus_source ) throws PhylogenyParserException, IOException {
         if ( nexus_source == null ) {
             throw new PhylogenyParserException( getClass() + ": attempt to parse null object." );
index c4243b4..a1ecfcd 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b4c18cf..24a11b1 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 8fa5b29..cdde33d 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -249,6 +249,7 @@ public final class NHXParser implements PhylogenyParser {
      * @throws NHXFormatException
      * @throws PhylogenyParserException
      */
+    @Override
     public Phylogeny[] parse() throws IOException, NHXFormatException {
         setHasNext( false );
         boolean in_comment = false;
@@ -539,6 +540,7 @@ public final class NHXParser implements PhylogenyParser {
      * @throws IOException
      * @throws PhylogenyParserException
      */
+    @Override
     public void setSource( final Object nhx_source ) throws PhylogenyParserException, IOException {
         if ( nhx_source == null ) {
             throw new PhylogenyParserException( getClass() + ": attempt to parse null object." );
@@ -743,8 +745,8 @@ public final class NHXParser implements PhylogenyParser {
                         if ( !node_to_annotate.getNodeData().isHasSequence() ) {
                             node_to_annotate.getNodeData().setSequence( new Sequence() );
                         }
-                        node_to_annotate.getNodeData().getSequence().setDomainArchitecture( new DomainArchitecture( s
-                                .substring( 3 ) ) );
+                        node_to_annotate.getNodeData().getSequence()
+                                .setDomainArchitecture( new DomainArchitecture( s.substring( 3 ) ) );
                     }
                     else if ( s.startsWith( NHXtags.NODE_IDENTIFIER ) ) {
                         node_to_annotate.getNodeData().setNodeIdentifier( new Identifier( s.substring( 3 ) ) );
index ae884ab..c6a16f9 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index bb80183..e53bf71 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6c82fa1..3181688 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6c013f6..a044239 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -60,8 +60,8 @@ import org.forester.phylogeny.data.Property;
 import org.forester.phylogeny.data.Reference;
 import org.forester.phylogeny.data.Sequence;
 import org.forester.phylogeny.data.SequenceRelation;
-import org.forester.phylogeny.data.Taxonomy;
 import org.forester.phylogeny.data.SequenceRelation.SEQUENCE_RELATION_TYPE;
+import org.forester.phylogeny.data.Taxonomy;
 import org.forester.util.FailedConditionCheckException;
 import org.forester.util.ForesterConstants;
 import org.forester.util.ForesterUtil;
@@ -312,8 +312,8 @@ public final class PhyloXmlHandler extends DefaultHandler {
                 if ( !node.getNodeData().isHasProperties() ) {
                     node.getNodeData().setProperties( new PropertiesMap() );
                 }
-                node.getNodeData().getProperties().addProperty( ( Property ) PropertyParser.getInstance()
-                        .parse( element ) );
+                node.getNodeData().getProperties()
+                        .addProperty( ( Property ) PropertyParser.getInstance().parse( element ) );
             }
         }
     }
@@ -385,8 +385,8 @@ public final class PhyloXmlHandler extends DefaultHandler {
                             .getAttribute( PhyloXmlMapping.PHYLOGENY_IS_REROOTABLE_ATTR ) ) );
                 }
                 if ( element.isHasAttribute( PhyloXmlMapping.PHYLOGENY_BRANCHLENGTH_UNIT_ATTR ) ) {
-                    getCurrentPhylogeny().setDistanceUnit( element
-                            .getAttribute( PhyloXmlMapping.PHYLOGENY_BRANCHLENGTH_UNIT_ATTR ) );
+                    getCurrentPhylogeny()
+                            .setDistanceUnit( element.getAttribute( PhyloXmlMapping.PHYLOGENY_BRANCHLENGTH_UNIT_ATTR ) );
                 }
                 if ( element.isHasAttribute( PhyloXmlMapping.PHYLOGENY_IS_ROOTED_ATTR ) ) {
                     getCurrentPhylogeny().setRooted( Boolean.parseBoolean( element
index 04a8cb6..7e2747d 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index e5fa2d0..5c08974 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -131,6 +131,7 @@ public class PhyloXmlParser implements PhylogenyParser {
         return _zipped_inputstream;
     }
 
+    @Override
     public Phylogeny[] parse() throws IOException, PhylogenyParserException {
         reset();
         final PhyloXmlHandler handler = new PhyloXmlHandler();
@@ -257,6 +258,7 @@ public class PhyloXmlParser implements PhylogenyParser {
         _warning_messages = new StringBuffer();
     }
 
+    @Override
     public void setSource( final Object source ) {
         _source = source;
     }
index 277dfa1..ec20b4d 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -40,6 +40,7 @@ public final class PhyloXmlUtil {
     public static final int         ROUNDING_DIGITS_FOR_PHYLOXML_DOUBLE_OUTPUT = 9;
     public static final String      VECTOR_PROPERTY_REF                        = "vector:index=";
     public static final String      VECTOR_PROPERTY_TYPE                       = "xsd:decimal";
+    public static final String      UNIPROT_TAX_PROVIDER                       = "uniprot";
     static {
         SEQUENCE_TYPES.add( "rna" );
         SEQUENCE_TYPES.add( "protein" );
index 442c937..beea81d 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 01d3c54..e5e5947 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -49,8 +49,8 @@ public class AccessionParser implements PhylogenyDataPhyloXmlParser {
     @Override
     public PhylogenyData parse( final XmlElement element ) throws PhylogenyParserException {
         if ( element.isHasAttribute( PhyloXmlMapping.ACCESSION_SOURCE_ATTR ) ) {
-            return new Accession( element.getValueAsString(), element
-                    .getAttribute( PhyloXmlMapping.ACCESSION_SOURCE_ATTR ) );
+            return new Accession( element.getValueAsString(),
+                                  element.getAttribute( PhyloXmlMapping.ACCESSION_SOURCE_ATTR ) );
         }
         else {
             return new Accession( element.getValueAsString(), "?" );
index 8f25921..00494f5 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 11469c4..dbd402e 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b65513b..c607603 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 02255ef..6d27c65 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 92ce6c7..c18d524 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 3f5add7..2e86f28 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index c211106..93db97e 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index f58448e..3c6a45f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6d68234..2f64245 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -50,8 +50,8 @@ public class IdentifierParser implements PhylogenyDataPhyloXmlParser {
     @Override
     public PhylogenyData parse( final XmlElement element ) throws PhylogenyParserException {
         if ( element.isHasAttribute( PhyloXmlMapping.IDENTIFIER_PROVIDER_ATTR ) ) {
-            return new Identifier( element.getValueAsString(), element
-                    .getAttribute( PhyloXmlMapping.IDENTIFIER_PROVIDER_ATTR ) );
+            return new Identifier( element.getValueAsString(),
+                                   element.getAttribute( PhyloXmlMapping.IDENTIFIER_PROVIDER_ATTR ) );
         }
         else if ( element.isHasAttribute( TYPE ) ) {
             return new Identifier( element.getValueAsString(), element.getAttribute( TYPE ) );
index 8ac0ee5..a2bd3be 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6d5ff38..395e14d 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 38f4dfb..b4baa8f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index cad2b26..47f0f17 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6c0a849..edd6d37 100644 (file)
@@ -53,22 +53,22 @@ public class SequenceRelationParser implements PhylogenyDataPhyloXmlParser {
             seqRelation.setType( SequenceRelation.SEQUENCE_RELATION_TYPE.valueOf( sType ) );
         }
         if ( element.isHasAttribute( PhyloXmlMapping.SEQUENCE_RELATION_ID_REF0 ) && ( _phylogeny != null ) ) {
-            final Sequence ref = PhyloXmlHandler.getSequenceMapByIdForPhylogeny( _phylogeny ).get( element
-                    .getAttribute( PhyloXmlMapping.SEQUENCE_RELATION_ID_REF0 ) );
+            final Sequence ref = PhyloXmlHandler.getSequenceMapByIdForPhylogeny( _phylogeny )
+                    .get( element.getAttribute( PhyloXmlMapping.SEQUENCE_RELATION_ID_REF0 ) );
             if ( ref != null ) {
                 seqRelation.setRef0( ref );
             }
         }
         if ( element.isHasAttribute( PhyloXmlMapping.SEQUENCE_RELATION_ID_REF1 ) && ( _phylogeny != null ) ) {
-            final Sequence ref = PhyloXmlHandler.getSequenceMapByIdForPhylogeny( _phylogeny ).get( element
-                    .getAttribute( PhyloXmlMapping.SEQUENCE_RELATION_ID_REF1 ) );
+            final Sequence ref = PhyloXmlHandler.getSequenceMapByIdForPhylogeny( _phylogeny )
+                    .get( element.getAttribute( PhyloXmlMapping.SEQUENCE_RELATION_ID_REF1 ) );
             if ( ref != null ) {
                 seqRelation.setRef1( ref );
             }
         }
         if ( element.isHasAttribute( PhyloXmlMapping.SEQUENCE_RELATION_DISTANCE ) ) {
-            seqRelation.setDistance( Double
-                    .valueOf( element.getAttribute( PhyloXmlMapping.SEQUENCE_RELATION_DISTANCE ) ) );
+            seqRelation
+                    .setDistance( Double.valueOf( element.getAttribute( PhyloXmlMapping.SEQUENCE_RELATION_DISTANCE ) ) );
         }
         for( int i = 0; i < element.getNumberOfChildElements(); ++i ) {
             final XmlElement child_element = element.getChildElement( i );
index d124ad0..879cd5a 100644 (file)
@@ -47,6 +47,7 @@ public class TaxonomyParser implements PhylogenyDataPhyloXmlParser {
     private TaxonomyParser() {
     }
 
+    @Override
     public Taxonomy parse( final XmlElement element ) throws PhylogenyParserException {
         final Taxonomy taxonomy = new Taxonomy();
         for( int i = 0; i < element.getNumberOfChildElements(); ++i ) {
index 57c106e..43404de 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 8968885..24aeeba 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -127,6 +127,7 @@ public class TolParser implements PhylogenyParser {
         return _zipped_inputstream;
     }
 
+    @Override
     public Phylogeny[] parse() throws IOException, PhylogenyParserException {
         reset();
         final TolXmlHandler handler = new TolXmlHandler();
@@ -246,6 +247,7 @@ public class TolParser implements PhylogenyParser {
         _warning_messages = new StringBuffer();
     }
 
+    @Override
     public void setSource( final Object source ) {
         _source = source;
     }
index c3b452d..975ca0d 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 09d5b24..bb8b6c9 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index e15472f..c94a60f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 586a709..1c11cb0 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2000-2009 Christian M. Zmasek
 // Copyright (C) 2007-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 630f057..c443842 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6e407f8..fa6e321 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -99,10 +99,12 @@ public class BasicMsa implements Msa {
         return _type;
     }
 
+    @Override
     public void setIdentifier( final int row, final Object id ) {
         _identifiers[ row ] = id;
     }
 
+    @Override
     public void setResidueAt( final int row, final int col, final char residue ) {
         _data[ row ][ col ] = residue;
     }
@@ -121,6 +123,7 @@ public class BasicMsa implements Msa {
         return sb.toString();
     }
 
+    @Override
     public void write( final Writer w ) throws IOException {
         final int max = determineMaxIdLength() + 1;
         for( int row = 0; row < _data.length; ++row ) {
index 644b5b5..b78cb32 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -86,14 +86,17 @@ public final class Mafft implements MsaInferrer {
         throw new NoSuchMethodError();
     }
 
+    @Override
     public String getErrorDescription() {
         return _error;
     }
 
+    @Override
     public int getExitCode() {
         return _exit_code;
     }
 
+    @Override
     public Msa infer( final File path_to_input_seqs, final List<String> opts ) throws IOException, InterruptedException {
         init();
         final List<String> my_opts = new ArrayList<String>();
index 323d94a..7301cc1 100644 (file)
@@ -32,14 +32,17 @@ public final class MafftOLD implements MsaInferrer {
         throw new NoSuchMethodError();
     }
 
+    @Override
     public String getErrorDescription() {
         return _error;
     }
 
+    @Override
     public int getExitCode() {
         return _exit_code;
     }
 
+    @Override
     public Msa infer( final File path_to_input_seqs, final List<String> opts ) throws IOException, InterruptedException {
         init();
         final String[] my_opts = new String[ opts.size() + 1 ];
index 2867989..0ee7844 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 949b072..791ccd9 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 801c247..593dd1f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index a2dfa06..7a53d20 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 7476cad..ad36c53 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 790518a..9df3549 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -93,6 +93,7 @@ public class BasicExternalNodeBasedCoverageExtender implements CoverageExtender
      *      org.forester.tools.modeling.CoverageCalculationOptions,
      *      java.io.PrintStream)
      */
+    @Override
     public List<String> find( final List<Phylogeny> phylogenies,
                               final List<String> already_covered,
                               int number_names_to_find,
index 815d13d..f1b2268 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -50,6 +50,7 @@ public class BranchCountingBasedScoringMethod implements ScoringMethodForExterna
         return score_contribution;
     }
 
+    @Override
     public void calculateScoreForExternalNode( final SortedMap<PhylogenyNode, Double> external_node_scores,
                                                final Phylogeny phylogeny,
                                                final PhylogenyNode external_node,
@@ -64,10 +65,12 @@ public class BranchCountingBasedScoringMethod implements ScoringMethodForExterna
         }
     }
 
+    @Override
     public String getDesciption() {
         return "sum of 1/branch-segment-sum";
     }
 
+    @Override
     public double getNormalizationFactor( final Phylogeny phylogeny ) {
         return ( 1.0 / phylogeny.getNumberOfExternalNodes() );
     }
index 7cddfdf..2b14bf4 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 59827f9..c5d90ff 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 638ca22..265e284 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 1d588ff..c757c3b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 8f60542..2f16ae1 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b882759..335b99b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index ee46c40..d56917b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -56,6 +56,7 @@ public class ExternalNodeBasedCoverage implements Coverage {
         _min = stats.getMin();
     }
 
+    @Override
     public String asString() {
         final StringBuffer sb = new StringBuffer();
         if ( getN() == 1 ) {
@@ -90,6 +91,7 @@ public class ExternalNodeBasedCoverage implements Coverage {
         return _n;
     }
 
+    @Override
     public double getScore() {
         return getAvarageNormalizedScore();
     }
index 5994bb9..a88018f 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -47,6 +47,7 @@ public class ExternalNodeBasedCoverageMethod implements CoverageCalculationMetho
     private static final Color MAXIMAL_COV_COLOR   = new Color( 0, 255, 0 );
     private static final Color MINIMAL_COV_COLOR   = new Color( 255, 0, 0 );
 
+    @Override
     public Coverage calculateCoverage( final List<Phylogeny> phylogenies,
                                        final List<String> names,
                                        final CoverageCalculationOptions options,
@@ -89,8 +90,10 @@ public class ExternalNodeBasedCoverageMethod implements CoverageCalculationMetho
         final SortedMap<PhylogenyNode, Double> external_node_scores = ModelingUtils
                 .setUpExternalCoverageHashMap( phylogeny );
         for( final Object element : names ) {
-            scoring_method.calculateScoreForExternalNode( external_node_scores, phylogeny, phylogeny
-                    .getNode( ( String ) element ), options );
+            scoring_method.calculateScoreForExternalNode( external_node_scores,
+                                                          phylogeny,
+                                                          phylogeny.getNode( ( String ) element ),
+                                                          options );
         }
         if ( annotate_phylogeny ) {
             colorizePhylogenyAccordingToCoverage( external_node_scores, phylogeny, normalization_factor );
index c88c35e..70b7265 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -41,6 +41,7 @@ public class ExternalNodeBasedCoverageMethodOptions implements CoverageCalculati
         _scoring_method = scoring_method;
     }
 
+    @Override
     public String asString() {
         final StringBuffer sb = new StringBuffer();
         sb.append( "scoring method: " );
index 9264e0e..62b4390 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 44eb20f..1614ca6 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 121bc4e..5fab38a 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d5bdbdc..9cb772f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -158,12 +158,11 @@ public class TestPccx {
             already_covered.add( "X" );
             already_covered.add( "H" );
             already_covered.add( "C" );
-            l = ce
-                    .find( phylogenies,
-                           already_covered,
-                           0,
-                           new ExternalNodeBasedCoverageMethodOptions( "org.forester.pccx.BranchCountingBasedScoringMethod" ),
-                           null );
+            l = ce.find( phylogenies,
+                         already_covered,
+                         0,
+                         new ExternalNodeBasedCoverageMethodOptions( "org.forester.pccx.BranchCountingBasedScoringMethod" ),
+                         null );
             if ( !l.get( 0 ).equals( "E" ) ) {
                 return false;
             }
index 234b2c1..c628b93 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index a3277ba..1a4892d 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 214337f..c427c25 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -89,14 +89,17 @@ public class PhylogenyBranch implements Edge {
         }
     }
 
+    @Override
     public PhylogenyData getData() {
         return _data;
     }
 
+    @Override
     public PhylogenyNode getFirstNode() {
         return _node_1;
     }
 
+    @Override
     public PhylogenyNode getSecondNode() {
         return _node_2;
     }
index 6569c81..f53e41a 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -894,8 +894,10 @@ public class PhylogenyMethods {
                         blue += child_color.getBlue();
                     }
                 }
-                setBranchColorValue( node, new Color( ForesterUtil.roundToInt( red / n ), ForesterUtil
-                        .roundToInt( green / n ), ForesterUtil.roundToInt( blue / n ) ) );
+                setBranchColorValue( node,
+                                     new Color( ForesterUtil.roundToInt( red / n ),
+                                                ForesterUtil.roundToInt( green / n ),
+                                                ForesterUtil.roundToInt( blue / n ) ) );
             }
         }
     }
@@ -913,8 +915,8 @@ public class PhylogenyMethods {
             parent.removeChildNode( remove_me );
             for( final PhylogenyNode desc : descs ) {
                 parent.addAsChild( desc );
-                desc.setDistanceToParent( addPhylogenyDistances( remove_me.getDistanceToParent(), desc
-                        .getDistanceToParent() ) );
+                desc.setDistanceToParent( addPhylogenyDistances( remove_me.getDistanceToParent(),
+                                                                 desc.getDistanceToParent() ) );
             }
             remove_me.setParent( null );
             phylogeny.setIdHash( null );
index 3858ea9..253c4c3 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -110,6 +110,7 @@ public class PhylogenyNode implements PhylogenyNodeI, Comparable<PhylogenyNode>
      * @param n
      *            the PhylogenyNode to add
      */
+    @Override
     final public void addAsChild( final PhylogenyNodeI node ) {
         final PhylogenyNode n = ( PhylogenyNode ) node;
         addChildNode( n );
@@ -128,6 +129,7 @@ public class PhylogenyNode implements PhylogenyNodeI, Comparable<PhylogenyNode>
         getDescendants().add( child );
     }
 
+    @Override
     final public int compareTo( final PhylogenyNode o ) {
         final PhylogenyNode n = o;
         if ( ( getName() == null ) || ( n.getName() == null ) ) {
@@ -300,6 +302,7 @@ public class PhylogenyNode implements PhylogenyNodeI, Comparable<PhylogenyNode>
      * @throws IllegalArgumentException
      *             if n is out of bounds
      */
+    @Override
     final public PhylogenyNode getChildNode( final int i ) {
         if ( isExternal() ) {
             throw new UnsupportedOperationException( "attempt to get the child node of an external node." );
@@ -371,6 +374,7 @@ public class PhylogenyNode implements PhylogenyNodeI, Comparable<PhylogenyNode>
      * Returns the length of the branch leading to the _parent of this
      * PhylogenyNode (double).
      */
+    @Override
     final public double getDistanceToParent() {
         return _distance_parent;
     }
@@ -458,6 +462,7 @@ public class PhylogenyNode implements PhylogenyNodeI, Comparable<PhylogenyNode>
     /**
      * Returns the ID (int) of this PhylogenyNode.
      */
+    @Override
     final public int getId() {
         return _id;
     }
@@ -465,6 +470,7 @@ public class PhylogenyNode implements PhylogenyNodeI, Comparable<PhylogenyNode>
     /**
      * Returns the name of this node.
      */
+    @Override
     final public String getName() {
         return getNodeData().getNodeName();
     }
@@ -809,6 +815,7 @@ public class PhylogenyNode implements PhylogenyNodeI, Comparable<PhylogenyNode>
      * Sets the length of the branch leading to the _parent of this
      * PhylogenyNode to double d.
      */
+    @Override
     final public void setDistanceToParent( final double d ) {
         _distance_parent = d;
     }
@@ -845,6 +852,7 @@ public class PhylogenyNode implements PhylogenyNodeI, Comparable<PhylogenyNode>
     /**
      * Sets the name of this node.
      */
+    @Override
     final public void setName( final String node_name ) {
         getNodeData().setNodeName( node_name );
     }
@@ -864,6 +872,7 @@ public class PhylogenyNode implements PhylogenyNodeI, Comparable<PhylogenyNode>
     /**
      * Sets the _parent PhylogenyNode of this PhylogenyNode to n.
      */
+    @Override
     final public void setParent( final PhylogenyNode n ) {
         _parent = n;
     }
index 3920875..ca81328 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 295b8b7..c2b4435 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -42,10 +42,12 @@ public class Accession implements PhylogenyData {
         _source = source;
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         return new StringBuffer( getValue() );
     }
 
+    @Override
     public StringBuffer asText() {
         final StringBuffer sb = new StringBuffer();
         if ( !ForesterUtil.isEmpty( getSource() ) ) {
@@ -57,6 +59,7 @@ public class Accession implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public PhylogenyData copy() {
         return new Accession( new String( getValue() ), new String( getSource() ) );
     }
@@ -94,6 +97,7 @@ public class Accession implements PhylogenyData {
         return getValue().hashCode();
     }
 
+    @Override
     public boolean isEqual( final PhylogenyData data ) {
         if ( this == data ) {
             return true;
@@ -108,6 +112,7 @@ public class Accession implements PhylogenyData {
         return ( a.getValue().equals( getValue() ) );
     }
 
+    @Override
     public StringBuffer toNHX() {
         final StringBuffer sb = new StringBuffer();
         sb.append( ":" );
@@ -116,6 +121,7 @@ public class Accession implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         if ( ForesterUtil.isEmpty( getSource() ) ) {
             PhylogenyDataUtil.appendElement( writer,
index cba8b55..a1d6b22 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 4b3bdd1..add1dfa 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 34a9dc0..6a517b8 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 803fbda..cfdf90d 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index dbb9d07..f701f80 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -48,10 +48,12 @@ public class Confidence implements PhylogenyData, Comparable<Confidence> {
         setType( type );
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         return new StringBuffer().append( ForesterUtil.FORMATTER_6.format( getValue() ) );
     }
 
+    @Override
     public StringBuffer asText() {
         final StringBuffer sb = new StringBuffer();
         if ( !ForesterUtil.isEmpty( getType() ) ) {
@@ -71,6 +73,7 @@ public class Confidence implements PhylogenyData, Comparable<Confidence> {
         return getType().compareToIgnoreCase( confidence.getType() );
     }
 
+    @Override
     public PhylogenyData copy() {
         return new Confidence( getValue(), getType() );
     }
@@ -88,6 +91,7 @@ public class Confidence implements PhylogenyData, Comparable<Confidence> {
         setType( "" );
     }
 
+    @Override
     public boolean isEqual( final PhylogenyData confidence ) {
         if ( confidence == null ) {
             return false;
@@ -113,6 +117,7 @@ public class Confidence implements PhylogenyData, Comparable<Confidence> {
         _value = value;
     }
 
+    @Override
     public StringBuffer toNHX() {
         final StringBuffer sb = new StringBuffer();
         sb.append( NHXtags.SUPPORT );
@@ -120,6 +125,7 @@ public class Confidence implements PhylogenyData, Comparable<Confidence> {
         return sb;
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         if ( getValue() == CONFIDENCE_DEFAULT_VALUE ) {
             return;
index 6e2b814..af70f80 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9a6ebdb..92c219d 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index e19c2ef..e93e742 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -96,6 +96,7 @@ public class DomainArchitecture implements PhylogenyData {
         _domains.put( key, pd );
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         final StringBuffer sb = new StringBuffer();
         for( int i = 0; i < getDomains().size(); ++i ) {
@@ -107,6 +108,7 @@ public class DomainArchitecture implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public StringBuffer asText() {
         final StringBuffer sb = new StringBuffer();
         for( int i = 0; i < getDomains().size(); ++i ) {
@@ -118,6 +120,7 @@ public class DomainArchitecture implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public PhylogenyData copy() {
         final List<PhylogenyData> domains = new ArrayList<PhylogenyData>( getDomains().size() );
         for( int i = 0; i < getDomains().size(); ++i ) {
@@ -153,6 +156,7 @@ public class DomainArchitecture implements PhylogenyData {
      * 
      * 
      */
+    @Override
     public boolean isEqual( final PhylogenyData domain_architecture ) {
         if ( domain_architecture == null ) {
             return false;
@@ -176,6 +180,7 @@ public class DomainArchitecture implements PhylogenyData {
         _total_length = total_length;
     }
 
+    @Override
     public StringBuffer toNHX() {
         final StringBuffer sb = new StringBuffer();
         sb.append( ":" );
@@ -196,6 +201,7 @@ public class DomainArchitecture implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         writer.write( ForesterUtil.LINE_SEPARATOR );
         writer.write( indentation );
index 22dacc9..c362f7c 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -107,6 +107,7 @@ public class Event implements PhylogenyData {
         }
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         final StringBuffer sb = new StringBuffer();
         if ( isUnassigned() ) {
@@ -140,6 +141,7 @@ public class Event implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public StringBuffer asText() {
         final StringBuffer sb = new StringBuffer();
         if ( isUnassigned() || isSpeciationOrDuplication() || isOther() || isRoot() || isTransfer() || isFusion() ) {
@@ -179,6 +181,7 @@ public class Event implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public PhylogenyData copy() {
         if ( isUnassigned() ) {
             return new Event();
@@ -220,6 +223,7 @@ public class Event implements PhylogenyData {
         return ( _duplications > 0 ) && ( _gene_losses < 1 ) && ( _speciations < 1 );
     }
 
+    @Override
     public boolean isEqual( final PhylogenyData event ) {
         if ( ( event == null ) || !( event instanceof Event ) ) {
             return false;
@@ -301,6 +305,7 @@ public class Event implements PhylogenyData {
         _event_type = EventType.mixed;
     }
 
+    @Override
     public StringBuffer toNHX() {
         final StringBuffer sb = new StringBuffer();
         if ( !isUnassigned() && ( isSpeciationOrDuplication() || isDuplication() || isSpeciation() ) ) {
@@ -319,6 +324,7 @@ public class Event implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         writer.write( ForesterUtil.LINE_SEPARATOR );
         writer.write( indentation );
index 33c3a8b..62dc722 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -52,10 +52,12 @@ public class Identifier implements PhylogenyData {
         _provider = provider;
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         return new StringBuffer( getValue() );
     }
 
+    @Override
     public StringBuffer asText() {
         final StringBuffer sb = new StringBuffer();
         if ( !ForesterUtil.isEmpty( getProvider() ) ) {
@@ -67,6 +69,7 @@ public class Identifier implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public PhylogenyData copy() {
         return new Identifier( getValue(), getProvider() );
     }
@@ -104,6 +107,7 @@ public class Identifier implements PhylogenyData {
         return getValue().hashCode();
     }
 
+    @Override
     public boolean isEqual( final PhylogenyData data ) {
         if ( this == data ) {
             return true;
@@ -118,6 +122,7 @@ public class Identifier implements PhylogenyData {
         return ( a.getValue().equals( getValue() ) );
     }
 
+    @Override
     public StringBuffer toNHX() {
         final StringBuffer sb = new StringBuffer();
         sb.append( ":" );
@@ -126,6 +131,7 @@ public class Identifier implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         if ( !org.forester.util.ForesterUtil.isEmpty( getProvider() ) ) {
             PhylogenyDataUtil.appendElement( writer,
index cce4be5..acf9ca0 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d1c75e2..89c4a86 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -86,14 +86,17 @@ public class NodeData implements PhylogenyData {
         _taxonomies.add( taxonomy );
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         throw new UnsupportedOperationException();
     }
 
+    @Override
     public StringBuffer asText() {
         throw new UnsupportedOperationException();
     }
 
+    @Override
     public PhylogenyData copy() {
         final NodeData new_data = new NodeData();
         new_data.setNodeName( getNodeName() );
@@ -237,6 +240,7 @@ public class NodeData implements PhylogenyData {
         return _taxonomies.get( index );
     }
 
+    @Override
     public boolean isEqual( final PhylogenyData data ) {
         throw new UnsupportedOperationException();
     }
@@ -413,6 +417,7 @@ public class NodeData implements PhylogenyData {
         }
     }
 
+    @Override
     public StringBuffer toNHX() {
         final StringBuffer sb = new StringBuffer();
         if ( isHasNodeIdentifier() ) {
@@ -433,6 +438,7 @@ public class NodeData implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         if ( isHasNodeIdentifier() ) {
             writer.write( ForesterUtil.LINE_SEPARATOR );
index d5be4d7..0bf8484 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index a90181d..f430477 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -357,8 +357,9 @@ public final class PhylogenyDataUtil {
     }
 
     public static void drawString( final String str, final double x, final double y, final Graphics g ) {
-        g.drawString( str, org.forester.util.ForesterUtil.roundToInt( x ), org.forester.util.ForesterUtil
-                .roundToInt( y ) );
+        g.drawString( str,
+                      org.forester.util.ForesterUtil.roundToInt( x ),
+                      org.forester.util.ForesterUtil.roundToInt( y ) );
     }
 
     public static String replaceIllegalXmlCharacters( final String value ) {
index 427d294..577a532 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 195590f..1a9d6a1 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9fd9904..d33ed01 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 81155ff..5bb947a 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -64,10 +64,12 @@ public class ProteinDomain implements PhylogenyData {
         _confidence = confidence;
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         return new StringBuffer( getName() );
     }
 
+    @Override
     public StringBuffer asText() {
         final StringBuffer sb = new StringBuffer( getName() );
         sb.append( " [" );
@@ -84,6 +86,7 @@ public class ProteinDomain implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public PhylogenyData copy() {
         if ( getId() == null ) {
             return new ProteinDomain( getName(), getFrom(), getTo(), getConfidence() );
@@ -115,6 +118,7 @@ public class ProteinDomain implements PhylogenyData {
         return _to;
     }
 
+    @Override
     public boolean isEqual( final PhylogenyData protein_domain ) {
         if ( protein_domain == null ) {
             return false;
@@ -131,10 +135,12 @@ public class ProteinDomain implements PhylogenyData {
         return true;
     }
 
+    @Override
     public StringBuffer toNHX() {
         throw new UnsupportedOperationException();
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         writer.write( ForesterUtil.LINE_SEPARATOR );
         writer.write( indentation );
index 01118a5..288a862 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -48,10 +48,12 @@ public class Reference implements PhylogenyData {
         _doi = doi;
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         return new StringBuffer( getDescription() );
     }
 
+    @Override
     public StringBuffer asText() {
         final StringBuffer sb = new StringBuffer();
         if ( !ForesterUtil.isEmpty( getDoi() ) ) {
@@ -63,6 +65,7 @@ public class Reference implements PhylogenyData {
         return sb;
     }
 
+    @Override
     public PhylogenyData copy() {
         return new Reference( getDescription(), getDoi() );
     }
@@ -75,6 +78,7 @@ public class Reference implements PhylogenyData {
         return _desc;
     }
 
+    @Override
     public boolean isEqual( final PhylogenyData data ) {
         if ( ( data == null ) || ( getDescription() == null ) ) {
             return false;
@@ -94,10 +98,12 @@ public class Reference implements PhylogenyData {
         _desc = value;
     }
 
+    @Override
     public StringBuffer toNHX() {
         throw new UnsupportedOperationException();
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         writer.write( ForesterUtil.LINE_SEPARATOR );
         writer.write( indentation );
index 27b3b0c..39ff08a 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -70,6 +70,7 @@ public class Sequence implements PhylogenyData, MultipleUris {
         getAnnotations().add( annotation );
     }
 
+    @Override
     public void addUri( final Uri uri ) {
         if ( getUris() == null ) {
             setUris( new ArrayList<Uri>() );
@@ -81,6 +82,7 @@ public class Sequence implements PhylogenyData, MultipleUris {
         _seq_relations.add( sr );
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         final StringBuffer sb = new StringBuffer();
         if ( getAccession() != null ) {
@@ -98,6 +100,7 @@ public class Sequence implements PhylogenyData, MultipleUris {
         return sb;
     }
 
+    @Override
     public StringBuffer asText() {
         return asSimpleText();
     }
@@ -106,6 +109,7 @@ public class Sequence implements PhylogenyData, MultipleUris {
      * Not a deep copy.
      * 
      */
+    @Override
     public PhylogenyData copy() {
         final Sequence seq = new Sequence();
         seq.setAnnotations( getAnnotations() );
@@ -213,10 +217,12 @@ public class Sequence implements PhylogenyData, MultipleUris {
         return _type;
     }
 
+    @Override
     public List<Uri> getUris() {
         return _uris;
     }
 
+    @Override
     public Uri getUri( final int index ) {
         return getUris().get( index );
     }
@@ -255,6 +261,7 @@ public class Sequence implements PhylogenyData, MultipleUris {
         setSourceId( null );
     }
 
+    @Override
     public boolean isEqual( final PhylogenyData data ) {
         if ( this == data ) {
             return true;
@@ -313,10 +320,12 @@ public class Sequence implements PhylogenyData, MultipleUris {
         _type = type;
     }
 
+    @Override
     public void setUris( final List<Uri> uris ) {
         _uris = uris;
     }
 
+    @Override
     public StringBuffer toNHX() {
         final StringBuffer sb = new StringBuffer();
         if ( getName().length() > 0 ) {
@@ -333,6 +342,7 @@ public class Sequence implements PhylogenyData, MultipleUris {
         return sb;
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         if ( isEmpty() ) {
             return;
index de50d59..b8ba724 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 026d68b..5d4411d 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -51,14 +51,17 @@ public class Taxonomy implements PhylogenyData, MultipleUris, Comparable<Taxonom
         init();
     }
 
+    @Override
     public StringBuffer asSimpleText() {
         return asText();
     }
 
+    @Override
     public Uri getUri( final int index ) {
         return getUris().get( index );
     }
 
+    @Override
     public void addUri( final Uri uri ) {
         if ( getUris() == null ) {
             setUris( new ArrayList<Uri>() );
@@ -66,6 +69,7 @@ public class Taxonomy implements PhylogenyData, MultipleUris, Comparable<Taxonom
         getUris().add( uri );
     }
 
+    @Override
     public StringBuffer asText() {
         final StringBuffer sb = new StringBuffer();
         if ( getIdentifier() != null ) {
@@ -101,6 +105,7 @@ public class Taxonomy implements PhylogenyData, MultipleUris, Comparable<Taxonom
         return sb;
     }
 
+    @Override
     public PhylogenyData copy() {
         final Taxonomy t = new Taxonomy();
         t.setTaxonomyCode( getTaxonomyCode() );
@@ -176,6 +181,7 @@ public class Taxonomy implements PhylogenyData, MultipleUris, Comparable<Taxonom
         return _taxonomy_code;
     }
 
+    @Override
     public List<Uri> getUris() {
         return _uris;
     }
@@ -228,6 +234,7 @@ public class Taxonomy implements PhylogenyData, MultipleUris, Comparable<Taxonom
      * (Note. This is important and should not be change without a very good reason.)
      * 
      */
+    @Override
     public boolean isEqual( final PhylogenyData data ) {
         if ( this == data ) {
             return true;
@@ -293,10 +300,12 @@ public class Taxonomy implements PhylogenyData, MultipleUris, Comparable<Taxonom
         _taxonomy_code = taxonomy_code;
     }
 
+    @Override
     public void setUris( final List<Uri> uris ) {
         _uris = uris;
     }
 
+    @Override
     public StringBuffer toNHX() {
         final StringBuffer sb = new StringBuffer();
         if ( getIdentifier() != null ) {
@@ -322,6 +331,7 @@ public class Taxonomy implements PhylogenyData, MultipleUris, Comparable<Taxonom
         return sb;
     }
 
+    @Override
     public void toPhyloXML( final Writer writer, final int level, final String indentation ) throws IOException {
         if ( isEmpty() ) {
             return;
index 06559fa..118a8e4 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 0d37507..dbe565e 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -36,10 +36,12 @@ import org.forester.phylogeny.Phylogeny;
  */
 public abstract class BasicPhylogenyFactory implements PhylogenyFactory {
 
+    @Override
     public Phylogeny create() {
         return new Phylogeny();
     }
 
+    @Override
     public Phylogeny[] create( final Object source, final Object creator ) throws IOException {
         return create( source, creator, null );
     }
index eab4efa..1828852 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -55,6 +55,7 @@ public class ParserBasedPhylogenyFactory extends BasicPhylogenyFactory {
         throw new CloneNotSupportedException();
     }
 
+    @Override
     public synchronized Phylogeny[] create( final Object source, final Object parser, final List<Object> parameters )
             throws IOException {
         if ( !( parser instanceof PhylogenyParser ) ) {
index ce90f03..565e31a 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 98bbf59..264f515 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -90,6 +90,7 @@ public class ChildNodeIteratorForward implements PhylogenyNodeIterator {
      * @return true is this iterator has at least one more element, false
      *         otherwise
      */
+    @Override
     public boolean hasNext() {
         return ( getI() < getNode().getNumberOfDescendants() );
     }
@@ -108,6 +109,7 @@ public class ChildNodeIteratorForward implements PhylogenyNodeIterator {
      * @throws NoSuchElementException
      *             if iteration is complete
      */
+    @Override
     public PhylogenyNode next() throws NoSuchElementException {
         if ( !hasNext() ) {
             throw new NoSuchElementException( "Attempt to call \"next()\" on iterator which has no more next elements." );
@@ -121,6 +123,7 @@ public class ChildNodeIteratorForward implements PhylogenyNodeIterator {
      * Not supported.
      * 
      */
+    @Override
     public void remove() {
         throw new UnsupportedOperationException();
     }
@@ -128,6 +131,7 @@ public class ChildNodeIteratorForward implements PhylogenyNodeIterator {
     /**
      * Resets the iterator.
      */
+    @Override
     public void reset() {
         setI( 0 );
     }
index f75e6f7..bf68269 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -75,6 +75,7 @@ public class ExternalForwardIterator implements PhylogenyNodeIterator {
      * 
      * @see java.util.Iterator#hasNext()
      */
+    @Override
     public boolean hasNext() {
         return getCurrentNode() != null;
     }
@@ -84,6 +85,7 @@ public class ExternalForwardIterator implements PhylogenyNodeIterator {
      * 
      * @see java.util.Iterator#next()
      */
+    @Override
     public PhylogenyNode next() throws NoSuchElementException {
         if ( !hasNext() ) {
             throw new NoSuchElementException( "Attempt to call \"next()\" on iterator which has no more next elements." );
@@ -102,6 +104,7 @@ public class ExternalForwardIterator implements PhylogenyNodeIterator {
      * Not supported.
      * 
      */
+    @Override
     public void remove() {
         throw new UnsupportedOperationException();
     }
@@ -109,6 +112,7 @@ public class ExternalForwardIterator implements PhylogenyNodeIterator {
     /**
      * DOCUMENT ME!
      */
+    @Override
     public void reset() {
         setCurrentNode( getFirstExtNode() );
     }
index 1b1450f..f5ab499 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -107,6 +107,7 @@ public class LevelOrderTreeIterator implements PhylogenyNodeIterator {
      * @return true is this iterator has at least one more element, false
      *         otherwise
      */
+    @Override
     public boolean hasNext() {
         return !getQueue().isEmpty();
     }
@@ -118,6 +119,7 @@ public class LevelOrderTreeIterator implements PhylogenyNodeIterator {
      * @throws NoSuchElementException
      *             if iteration is complete
      */
+    @Override
     public PhylogenyNode next() throws NoSuchElementException {
         if ( !hasNext() ) {
             throw new NoSuchElementException( "Attempt to call \"next()\" on iterator which has no more next elements." );
@@ -133,6 +135,7 @@ public class LevelOrderTreeIterator implements PhylogenyNodeIterator {
      * Not supported.
      * 
      */
+    @Override
     public void remove() {
         throw new UnsupportedOperationException();
     }
@@ -140,6 +143,7 @@ public class LevelOrderTreeIterator implements PhylogenyNodeIterator {
     /**
      * Resets the iterator.
      */
+    @Override
     public void reset() {
         getQueue().clear();
         getQueue().enqueue( getRoot() );
index 587ab51..f10aecd 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -38,8 +38,10 @@ import org.forester.phylogeny.PhylogenyNode;
  */
 public interface PhylogenyNodeIterator extends Iterator<PhylogenyNode> {
 
+    @Override
     public boolean hasNext();
 
+    @Override
     public PhylogenyNode next() throws NoSuchElementException;
 
     public void reset();
index 9f06e50..b18562a 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 1405476..0d06ff9 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -72,6 +72,7 @@ public class PostorderTreeIterator implements PhylogenyNodeIterator {
      * 
      * @return DOCUMENT ME!
      */
+    @Override
     public boolean hasNext() {
         return _has_next;
     }
@@ -79,6 +80,7 @@ public class PostorderTreeIterator implements PhylogenyNodeIterator {
     /**
      * Advances the Iterator by one.
      */
+    @Override
     public PhylogenyNode next() throws NoSuchElementException {
         if ( !hasNext() ) {
             throw new NoSuchElementException( "Attempt to call \"next()\" on iterator which has no more next elements." );
@@ -109,6 +111,7 @@ public class PostorderTreeIterator implements PhylogenyNodeIterator {
      * Not supported.
      * 
      */
+    @Override
     public void remove() {
         throw new UnsupportedOperationException();
     }
@@ -116,6 +119,7 @@ public class PostorderTreeIterator implements PhylogenyNodeIterator {
     /**
      * DOCUMENT ME!
      */
+    @Override
     public void reset() {
         setHasNext( true );
         getStack().clear();
index 18928db..c01434b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -75,6 +75,7 @@ public class PreorderTreeIterator implements PhylogenyNodeIterator {
      * 
      * @see java.util.Iterator#hasNext()
      */
+    @Override
     public boolean hasNext() {
         return !getStack().isEmpty();
     }
@@ -82,6 +83,7 @@ public class PreorderTreeIterator implements PhylogenyNodeIterator {
     /**
      * Advances the Iterator by one.
      */
+    @Override
     public PhylogenyNode next() throws NoSuchElementException {
         if ( !hasNext() ) {
             throw new NoSuchElementException( "Attempt to call \"next()\" on iterator which has no more next elements." );
@@ -99,10 +101,12 @@ public class PreorderTreeIterator implements PhylogenyNodeIterator {
      * Not supported.
      * 
      */
+    @Override
     public void remove() {
         throw new UnsupportedOperationException();
     }
 
+    @Override
     public void reset() {
         getStack().clear();
         getStack().push( getTree().getRoot() );
index 51b4201..dc72099 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b6641bb..9b18e81 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 4271890..a64fbad 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d2c79ee..2da3a70 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 7855473..f6dda23 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b21b9b5..6f163cc 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index f75f6f8..98f1cc5 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 4509685..af6653a 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d7786c0..b7ef358 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 3e3fe86..6e4a2a8 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6cf3c72..0c67a61 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 37426e4..20bfe6f 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2000-2001 Washington University School of Medicine
 // and Howard Hughes Medical Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -105,6 +105,7 @@ class Tuplet implements Comparable<Tuplet> {
         }
     }
 
+    @Override
     public int compareTo( final Tuplet n ) {
         if ( ( getValue1() != Tuplet.DEFAULT ) && ( n.getValue1() != Tuplet.DEFAULT ) ) {
             if ( getValue1() < n.getValue1() ) {
index 4cc03a7..ed56ed8 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -45,22 +45,27 @@ public class BasicSequence implements Sequence {
         _type = type;
     }
 
+    @Override
     public Object getIdentifier() {
         return _identifier;
     }
 
+    @Override
     public int getLength() {
         return _mol_sequence.length;
     }
 
+    @Override
     public char[] getMolecularSequence() {
         return _mol_sequence;
     }
 
+    @Override
     public char getResidueAt( final int position ) {
         return _mol_sequence[ position ];
     }
 
+    @Override
     public TYPE getType() {
         return _type;
     }
index 3ee5893..b794af9 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 43bb0e3..bb3a8a9 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index adfd02c..d760297 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9436ce9..6861942 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -92,10 +92,12 @@ public class BasicBinaryDomainCombination implements BinaryDomainCombination {
         }
     }
 
+    @Override
     public DomainId getId0() {
         return _id_0;
     }
 
+    @Override
     public DomainId getId1() {
         return _id_1;
     }
@@ -105,6 +107,7 @@ public class BasicBinaryDomainCombination implements BinaryDomainCombination {
         return getId0().hashCode() + ( 19 * getId1().hashCode() );
     }
 
+    @Override
     public StringBuffer toGraphDescribingLanguage( final OutputFormat format,
                                                    final String node_attribute,
                                                    final String edge_attribute ) {
index 9f108cc..bfc13ce 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -50,6 +50,7 @@ public class BasicCombinableDomains implements CombinableDomains {
         init();
     }
 
+    @Override
     public void addCombinableDomain( final DomainId protein_domain ) {
         if ( getCombiningDomains().containsKey( protein_domain ) ) {
             getCombiningDomains().put( protein_domain, getCombiningDomains().get( protein_domain ) + 1 );
@@ -59,6 +60,7 @@ public class BasicCombinableDomains implements CombinableDomains {
         }
     }
 
+    @Override
     public List<DomainId> getAllDomains() {
         final List<DomainId> domains = getCombinableDomains();
         if ( !domains.contains( getKeyDomain() ) ) {
@@ -67,6 +69,7 @@ public class BasicCombinableDomains implements CombinableDomains {
         return domains;
     }
 
+    @Override
     public List<DomainId> getCombinableDomains() {
         final List<DomainId> domains = new ArrayList<DomainId>( getNumberOfCombinableDomains() );
         for( final DomainId domain : getCombiningDomains().keySet() ) {
@@ -75,6 +78,7 @@ public class BasicCombinableDomains implements CombinableDomains {
         return domains;
     }
 
+    @Override
     public SortedMap<DomainId, Integer> getCombinableDomainsIds() {
         final SortedMap<DomainId, Integer> ids = new TreeMap<DomainId, Integer>();
         for( final DomainId domain : getCombiningDomains().keySet() ) {
@@ -84,6 +88,7 @@ public class BasicCombinableDomains implements CombinableDomains {
         return ids;
     }
 
+    @Override
     public StringBuilder getCombiningDomainIdsAsStringBuilder() {
         final StringBuilder sb = new StringBuilder();
         for( final Iterator<DomainId> iter = getCombiningDomains().keySet().iterator(); iter.hasNext(); ) {
@@ -104,26 +109,32 @@ public class BasicCombinableDomains implements CombinableDomains {
         return _combining_domains;
     }
 
+    @Override
     public DomainId getKeyDomain() {
         return _key_domain;
     }
 
+    @Override
     public DescriptiveStatistics getKeyDomainConfidenceDescriptiveStatistics() {
         return _key_domain_confidence_statistics;
     }
 
+    @Override
     public int getKeyDomainCount() {
         return _key_domain_count;
     }
 
+    @Override
     public int getKeyDomainProteinsCount() {
         return _key_domain_proteins_count;
     }
 
+    @Override
     public int getNumberOfCombinableDomains() {
         return _combining_domains.size();
     }
 
+    @Override
     public int getNumberOfProteinsExhibitingCombination( final DomainId protein_domain ) {
         if ( getCombiningDomains().containsKey( protein_domain ) ) {
             return getCombiningDomains().get( protein_domain );
@@ -133,6 +144,7 @@ public class BasicCombinableDomains implements CombinableDomains {
         }
     }
 
+    @Override
     public Species getSpecies() {
         return _species;
     }
@@ -143,18 +155,22 @@ public class BasicCombinableDomains implements CombinableDomains {
         _key_domain_confidence_statistics = null;
     }
 
+    @Override
     public boolean isCombinable( final DomainId protein_domain ) {
         return getCombiningDomains().containsKey( protein_domain );
     }
 
+    @Override
     public void setKeyDomainConfidenceDescriptiveStatistics( final DescriptiveStatistics key_domain_confidence_statistics ) {
         _key_domain_confidence_statistics = key_domain_confidence_statistics;
     }
 
+    @Override
     public void setKeyDomainCount( final int key_domain_count ) {
         _key_domain_count = key_domain_count;
     }
 
+    @Override
     public void setKeyDomainProteinsCount( final int key_domain_proteins_count ) {
         _key_domain_proteins_count = key_domain_proteins_count;
     }
index a5a2da5..1c9ba39 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -120,6 +120,7 @@ public class BasicDomain implements Domain {
         _per_domain_score = per_domain_score;
     }
 
+    @Override
     public void addGoId( final GoId go_id ) {
         getDomainId().getGoIds().add( go_id );
     }
@@ -129,6 +130,7 @@ public class BasicDomain implements Domain {
      * insensitive) and their numbers.
      * 
      */
+    @Override
     public int compareTo( final Domain domain ) {
         if ( domain.getClass() != this.getClass() ) {
             throw new IllegalArgumentException( "attempt to compare [" + domain.getClass() + "] to " + "["
@@ -162,22 +164,27 @@ public class BasicDomain implements Domain {
         }
     }
 
+    @Override
     public DomainId getDomainId() {
         return _id;
     }
 
+    @Override
     public int getFrom() {
         return _from;
     }
 
+    @Override
     public GoId getGoId( final int i ) {
         return getDomainId().getGoIds().get( i );
     }
 
+    @Override
     public short getNumber() {
         return _number;
     }
 
+    @Override
     public int getNumberOfGoIds() {
         return getDomainId().getGoIds().size();
     }
@@ -192,18 +199,22 @@ public class BasicDomain implements Domain {
         return _per_domain_score;
     }
 
+    @Override
     public double getPerSequenceEvalue() {
         return _per_sequence_evalue;
     }
 
+    @Override
     public double getPerSequenceScore() {
         return _per_sequence_score;
     }
 
+    @Override
     public int getTo() {
         return _to;
     }
 
+    @Override
     public short getTotalCount() {
         return _total_count;
     }
index 5b5a91e..3b7b587 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -51,6 +51,7 @@ public class BasicDomainSimilarityCalculator implements DomainSimilarityCalculat
         _treat_as_binary_comparison = treat_as_binary_comparison;
     }
 
+    @Override
     public SortedSet<DomainSimilarity> calculateSimilarities( final PairwiseDomainSimilarityCalculator pairwise_calculator,
                                                               final List<GenomeWideCombinableDomains> cdc_list,
                                                               final boolean ignore_domains_without_combinations_in_any_genome,
@@ -142,8 +143,8 @@ public class BasicDomainSimilarityCalculator implements DomainSimilarityCalculat
         }
         final DescriptiveStatistics stat = new BasicDescriptiveStatistics();
         final SortedMap<Species, SpeciesSpecificDomainSimilariyData> species_data = new TreeMap<Species, SpeciesSpecificDomainSimilariyData>();
-        species_data.put( domains_list.get( 0 ).getSpecies(), createSpeciesSpecificDomainSimilariyData( domains_list
-                .get( 0 ) ) );
+        species_data.put( domains_list.get( 0 ).getSpecies(),
+                          createSpeciesSpecificDomainSimilariyData( domains_list.get( 0 ) ) );
         int max_difference_in_counts = 0;
         int max_difference = 0;
         final boolean is_domain_combination_based = pairwise_calculator instanceof CombinationsBasedPairwiseDomainSimilarityCalculator;
@@ -231,9 +232,10 @@ public class BasicDomainSimilarityCalculator implements DomainSimilarityCalculat
     }
 
     private static SpeciesSpecificDomainSimilariyData createSpeciesSpecificDomainSimilariyData( final CombinableDomains cd ) {
-        final SpeciesSpecificDomainSimilariyData sd = new PrintableSpeciesSpecificDomainSimilariyData( cd
-                .getKeyDomainProteinsCount(), cd.getKeyDomainCount(), cd.getNumberOfCombinableDomains(), cd
-                .getKeyDomainConfidenceDescriptiveStatistics() );
+        final SpeciesSpecificDomainSimilariyData sd = new PrintableSpeciesSpecificDomainSimilariyData( cd.getKeyDomainProteinsCount(),
+                                                                                                       cd.getKeyDomainCount(),
+                                                                                                       cd.getNumberOfCombinableDomains(),
+                                                                                                       cd.getKeyDomainConfidenceDescriptiveStatistics() );
         for( final DomainId domain : cd.getCombinableDomains() ) {
             sd.addProteinsExhibitingCombinationCount( domain, cd.getNumberOfProteinsExhibitingCombination( domain ) );
         }
index ca8bff0..d70f915 100644 (file)
@@ -27,10 +27,10 @@ public class BasicGenomeWideCombinableDomains implements GenomeWideCombinableDom
     private final static NumberFormat                    FORMATTER                                  = new DecimalFormat( "0.0E0" );
     private static final Comparator<CombinableDomains>   DESCENDING_KEY_DOMAIN_COUNT_ORDER          = new Comparator<CombinableDomains>() {
 
+                                                                                                        @Override
                                                                                                         public int compare( final CombinableDomains d1,
                                                                                                                             final CombinableDomains d2 ) {
-                                                                                                            if ( d1
-                                                                                                                    .getKeyDomainCount() < d2
+                                                                                                            if ( d1.getKeyDomainCount() < d2
                                                                                                                     .getKeyDomainCount() ) {
                                                                                                                 return 1;
                                                                                                             }
@@ -51,10 +51,10 @@ public class BasicGenomeWideCombinableDomains implements GenomeWideCombinableDom
                                                                                                     };
     private static final Comparator<CombinableDomains>   DESCENDING_KEY_DOMAIN_PROTEINS_COUNT_ORDER = new Comparator<CombinableDomains>() {
 
+                                                                                                        @Override
                                                                                                         public int compare( final CombinableDomains d1,
                                                                                                                             final CombinableDomains d2 ) {
-                                                                                                            if ( d1
-                                                                                                                    .getKeyDomainProteinsCount() < d2
+                                                                                                            if ( d1.getKeyDomainProteinsCount() < d2
                                                                                                                     .getKeyDomainProteinsCount() ) {
                                                                                                                 return 1;
                                                                                                             }
@@ -75,10 +75,10 @@ public class BasicGenomeWideCombinableDomains implements GenomeWideCombinableDom
                                                                                                     };
     private static final Comparator<CombinableDomains>   DESCENDING_COMBINATIONS_COUNT_ORDER        = new Comparator<CombinableDomains>() {
 
+                                                                                                        @Override
                                                                                                         public int compare( final CombinableDomains d1,
                                                                                                                             final CombinableDomains d2 ) {
-                                                                                                            if ( d1
-                                                                                                                    .getNumberOfCombinableDomains() < d2
+                                                                                                            if ( d1.getNumberOfCombinableDomains() < d2
                                                                                                                     .getNumberOfCombinableDomains() ) {
                                                                                                                 return 1;
                                                                                                             }
@@ -111,14 +111,17 @@ public class BasicGenomeWideCombinableDomains implements GenomeWideCombinableDom
         _combinable_domains_map.put( key, cdc );
     }
 
+    @Override
     public boolean contains( final DomainId key_id ) {
         return _combinable_domains_map.containsKey( key_id );
     }
 
+    @Override
     public CombinableDomains get( final DomainId key_id ) {
         return _combinable_domains_map.get( key_id );
     }
 
+    @Override
     public SortedMap<DomainId, CombinableDomains> getAllCombinableDomainsIds() {
         return _combinable_domains_map;
     }
@@ -164,10 +167,12 @@ public class BasicGenomeWideCombinableDomains implements GenomeWideCombinableDom
         return stats;
     }
 
+    @Override
     public int getSize() {
         return _combinable_domains_map.size();
     }
 
+    @Override
     public Species getSpecies() {
         return _species;
     }
@@ -191,6 +196,7 @@ public class BasicGenomeWideCombinableDomains implements GenomeWideCombinableDom
 
     // Produces something like: 
     // 2-oxoacid_dh      5       5       2       4.8E-67   Biotin_lipoyl [4], E3_binding [3]
+    @Override
     public StringBuilder toStringBuilder( final GenomeWideCombinableDomainsSortOrder sort_order ) {
         final StringBuilder sb = new StringBuilder();
         final List<CombinableDomains> combinable_domains = new ArrayList<CombinableDomains>();
@@ -213,14 +219,12 @@ public class BasicGenomeWideCombinableDomains implements GenomeWideCombinableDom
             sb.append( ForesterUtil.pad( new StringBuffer( "" + cb.getKeyDomainCount() ), 8, ' ', false ) );
             sb.append( ForesterUtil.pad( new StringBuffer( "" + cb.getKeyDomainProteinsCount() ), 8, ' ', false ) );
             sb.append( ForesterUtil.pad( new StringBuffer( "" + cb.getNumberOfCombinableDomains() ), 8, ' ', false ) );
-            sb
-                    .append( ForesterUtil
-                            .pad( new StringBuffer( ""
-                                          + FORMATTER
-                                                  .format( cb.getKeyDomainConfidenceDescriptiveStatistics().median() ) ),
-                                  10,
-                                  ' ',
-                                  false ) );
+            sb.append( ForesterUtil.pad( new StringBuffer( ""
+                                                 + FORMATTER.format( cb.getKeyDomainConfidenceDescriptiveStatistics()
+                                                         .median() ) ),
+                                         10,
+                                         ' ',
+                                         false ) );
             sb.append( cb.getCombiningDomainIdsAsStringBuilder() );
             sb.append( ForesterUtil.getLineSeparator() );
         }
index bc67c18..93949d1 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -47,6 +47,7 @@ public class BasicProtein implements Protein {
         init();
     }
 
+    @Override
     public void addProteinDomain( final Domain protein_domain ) {
         getProteinDomains().add( protein_domain );
     }
@@ -113,14 +114,17 @@ public class BasicProtein implements Protein {
         return _name;
     }
 
+    @Override
     public int getNumberOfProteinDomains() {
         return getProteinDomains().size();
     }
 
+    @Override
     public Domain getProteinDomain( final int index ) {
         return _protein_domains.get( index );
     }
 
+    @Override
     public int getProteinDomainCount( final DomainId domain_id ) {
         return getProteinDomains( domain_id ).size();
     }
@@ -133,10 +137,12 @@ public class BasicProtein implements Protein {
         return ids;
     }
 
+    @Override
     public List<Domain> getProteinDomains() {
         return _protein_domains;
     }
 
+    @Override
     public List<Domain> getProteinDomains( final DomainId domain_id ) {
         final List<Domain> domains = new ArrayList<Domain>();
         for( final Domain domain : getProteinDomains() ) {
@@ -147,10 +153,12 @@ public class BasicProtein implements Protein {
         return domains;
     }
 
+    @Override
     public ProteinId getProteinId() {
         return _id;
     }
 
+    @Override
     public Species getSpecies() {
         return _species;
     }
index e425b39..282109e 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -67,6 +67,7 @@ public class BasicSpecies implements Species {
     /* (non-Javadoc)
      * @see org.forester.surfacing.Species#getSpeciesId()
      */
+    @Override
     public String getSpeciesId() {
         return _species_id;
     }
index 3637dfe..352211a 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -44,6 +44,7 @@ public interface BinaryDomainCombination extends Comparable<BinaryDomainCombinat
      * 
      * @return a String representation in the form id0 - id1
      */
+    @Override
     public String toString();
 
     public static enum DomainCombinationType {
index 05fffbf..581deb3 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b3035c5..3b0c6dc 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -64,6 +64,7 @@ public class CombinationsBasedPairwiseDomainSimilarity implements PairwiseDomain
         return _same_domains;
     }
 
+    @Override
     public double getSimilarityScore() {
         return _score;
     }
index a33527d..2bb2524 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -31,6 +31,7 @@ import java.util.List;
 
 public class CombinationsBasedPairwiseDomainSimilarityCalculator implements PairwiseDomainSimilarityCalculator {
 
+    @Override
     public PairwiseDomainSimilarity calculateSimilarity( final CombinableDomains domains_1,
                                                          final CombinableDomains domains_2 ) {
         if ( !domains_1.getKeyDomain().equals( domains_2.getKeyDomain() ) ) {
index b1abfeb..4de0d28 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -55,10 +55,12 @@ public class CountsBasedPairwiseDomainSimilarity implements PairwiseDomainSimila
      * Returns (counts for domain 1) minus (counts for domain 2).
      * 
      */
+    @Override
     public int getDifferenceInCounts() {
         return _copy_number_difference;
     }
 
+    @Override
     public double getSimilarityScore() {
         return _score;
     }
index 4fa9179..c47a278 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 2103d26..24943a1 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index c2baf20..41a916c 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 317bec3..c9ff524 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d902e75..c61dcad 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -29,6 +29,7 @@ package org.forester.surfacing;
 
 public class DomainCountsBasedPairwiseSimilarityCalculator implements PairwiseDomainSimilarityCalculator {
 
+    @Override
     public PairwiseDomainSimilarity calculateSimilarity( final CombinableDomains domains_1,
                                                          final CombinableDomains domains_2 ) {
         if ( !domains_1.getKeyDomain().equals( domains_2.getKeyDomain() ) ) {
index a36aa12..6996ef3 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -72,8 +72,8 @@ public final class DomainCountsDifferenceUtil {
         }
         if ( bdc.contains( dc )
                 && ( ( ( BasicCombinableDomains ) genome.get( dc.getId0() ) ).getCombiningDomains().get( dc.getId1() ) != null ) ) {
-            final int count = ( ( BasicCombinableDomains ) genome.get( dc.getId0() ) ).getCombiningDomains().get( dc
-                    .getId1() );
+            final int count = ( ( BasicCombinableDomains ) genome.get( dc.getId0() ) ).getCombiningDomains()
+                    .get( dc.getId1() );
             copy_counts.get( dc ).add( count );
         }
         else {
@@ -220,16 +220,22 @@ public final class DomainCountsDifferenceUtil {
             for( final GenomeWideCombinableDomains genome : genomes ) {
                 final String species = genome.getSpecies().getSpeciesId();
                 if ( high_copy_base_species.contains( species ) ) {
-                    DomainCountsDifferenceUtil.addCounts( high_copy_base_copy_counts_dc, dc, genome, bdcs_per_genome
-                            .get( species ) );
+                    DomainCountsDifferenceUtil.addCounts( high_copy_base_copy_counts_dc,
+                                                          dc,
+                                                          genome,
+                                                          bdcs_per_genome.get( species ) );
                 }
                 if ( high_copy_target_species.contains( species ) ) {
-                    DomainCountsDifferenceUtil.addCounts( high_copy_target_copy_counts_dc, dc, genome, bdcs_per_genome
-                            .get( species ) );
+                    DomainCountsDifferenceUtil.addCounts( high_copy_target_copy_counts_dc,
+                                                          dc,
+                                                          genome,
+                                                          bdcs_per_genome.get( species ) );
                 }
                 if ( low_copy_species.contains( species ) ) {
-                    DomainCountsDifferenceUtil.addCounts( low_copy_copy_counts_dc, dc, genome, bdcs_per_genome
-                            .get( species ) );
+                    DomainCountsDifferenceUtil.addCounts( low_copy_copy_counts_dc,
+                                                          dc,
+                                                          genome,
+                                                          bdcs_per_genome.get( species ) );
                 }
             }
         }
@@ -485,8 +491,8 @@ public final class DomainCountsDifferenceUtil {
         }
         html_writer.write( "</td><td>" );
         if ( bdcs_per_genome.get( species ).contains( bdc ) && ( copy_means.get( bdc ) > 0 ) ) {
-            final int count = ( ( BasicCombinableDomains ) genome.get( bdc.getId0() ) ).getCombiningDomains().get( bdc
-                    .getId1() );
+            final int count = ( ( BasicCombinableDomains ) genome.get( bdc.getId0() ) ).getCombiningDomains()
+                    .get( bdc.getId1() );
             html_writer.write( count + "" );
         }
         else {
index 18a4a4d..0ab1039 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9e39b9e..0e96aca 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2010 Christian M. Zmasek
 // Copyright (C) 2008-2010 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 4b6ca22..f154f1d 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2010 Christian M. Zmasek
 // Copyright (C) 2008-2010 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 82de445..2396b90 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index bdf227c..724aa70 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 4a4c91f..27ea841 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index e1c6cc6..537f44f 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 8204dbc..69a6a31 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d1f67d0..8880b05 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index f0e04ca..291a350 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index ae94f81..789574a 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -233,9 +233,11 @@ public class PairwiseGenomeComparator {
                 // - 1 ) );
                 if ( pw_stats != null ) {
                     if ( pw_stats.getMin() >= pw_stats.getMax() ) {
-                        ForesterUtil.printWarningMessage( command_line_prg_name, "for [" + species_i + "-" + species_j
-                                + "] score minimum is [" + pw_stats.getMin() + "] while score maximum is ["
-                                + pw_stats.getMax() + "], possibly indicating that a genome is compared to itself" );
+                        ForesterUtil
+                                .printWarningMessage( command_line_prg_name, "for [" + species_i + "-" + species_j
+                                        + "] score minimum is [" + pw_stats.getMin() + "] while score maximum is ["
+                                        + pw_stats.getMax()
+                                        + "], possibly indicating that a genome is compared to itself" );
                     }
                     if ( display_histograms && ( pw_stats.getMin() < pw_stats.getMax() ) ) {
                         //final double[] values = pw_stats.getDataAsDoubleArray();
index 0fb075e..d5b6b4d 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -273,6 +273,7 @@ public class PrintableDomainSimilarity implements DomainSimilarity {
         }
     }
 
+    @Override
     public int compareTo( final DomainSimilarity domain_similarity ) {
         if ( this == domain_similarity ) {
             return PrintableDomainSimilarity.EQUAL;
@@ -418,6 +419,7 @@ public class PrintableDomainSimilarity implements DomainSimilarity {
         throw new AssertionError( "Unknown sort method: " + getSortField() );
     }
 
+    @Override
     public SortedSet<DomainId> getCombinableDomainIds( final Species species_of_combinable_domain ) {
         final SortedSet<DomainId> sorted_ids = new TreeSet<DomainId>();
         if ( getSpeciesData().containsKey( species_of_combinable_domain ) ) {
@@ -437,6 +439,7 @@ public class PrintableDomainSimilarity implements DomainSimilarity {
         return _detailedness;
     }
 
+    @Override
     public DomainId getDomainId() {
         return getCombinableDomains().getKeyDomain();
     }
@@ -453,6 +456,7 @@ public class PrintableDomainSimilarity implements DomainSimilarity {
         return _go_namespace_limit;
     }
 
+    @Override
     public int getMaximalDifference() {
         return _max_difference;
     }
@@ -462,18 +466,22 @@ public class PrintableDomainSimilarity implements DomainSimilarity {
         return _max_difference_in_counts;
     }
 
+    @Override
     public double getMaximalSimilarityScore() {
         return _max;
     }
 
+    @Override
     public double getMeanSimilarityScore() {
         return _mean;
     }
 
+    @Override
     public double getMinimalSimilarityScore() {
         return _min;
     }
 
+    @Override
     public int getN() {
         return _n;
     }
@@ -482,6 +490,7 @@ public class PrintableDomainSimilarity implements DomainSimilarity {
         return _sort_field;
     }
 
+    @Override
     public SortedSet<Species> getSpecies() {
         final SortedSet<Species> species = new TreeSet<Species>();
         for( final Species s : getSpeciesData().keySet() ) {
@@ -494,6 +503,7 @@ public class PrintableDomainSimilarity implements DomainSimilarity {
         return _species_order;
     }
 
+    @Override
     public SortedMap<Species, SpeciesSpecificDomainSimilariyData> getSpeciesData() {
         return _species_data;
     }
@@ -520,6 +530,7 @@ public class PrintableDomainSimilarity implements DomainSimilarity {
         return sb;
     }
 
+    @Override
     public double getStandardDeviationOfSimilarityScore() {
         return _sd;
     }
@@ -566,6 +577,7 @@ public class PrintableDomainSimilarity implements DomainSimilarity {
         return toStringBuffer( null ).toString();
     }
 
+    @Override
     public StringBuffer toStringBuffer( final PrintableDomainSimilarity.PRINT_OPTION print_option ) {
         switch ( print_option ) {
             case SIMPLE_TAB_DELIMITED:
index 9c36890..6733e4f 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -55,6 +55,7 @@ class PrintableSpeciesSpecificDomainSimilariyData implements SpeciesSpecificDoma
         _combinable_domain_id_to_count_map = new TreeMap<DomainId, Integer>();
     }
 
+    @Override
     public void addProteinsExhibitingCombinationCount( final DomainId domain_id, final int count ) {
         if ( getCombinableDomainIdToCountsMap().containsKey( domain_id ) ) {
             throw new IllegalArgumentException( "Domain with id " + domain_id + " already exists" );
@@ -62,6 +63,7 @@ class PrintableSpeciesSpecificDomainSimilariyData implements SpeciesSpecificDoma
         getCombinableDomainIdToCountsMap().put( domain_id, count );
     }
 
+    @Override
     public SortedMap<DomainId, Integer> getCombinableDomainIdToCountsMap() {
         return _combinable_domain_id_to_count_map;
     }
@@ -82,6 +84,7 @@ class PrintableSpeciesSpecificDomainSimilariyData implements SpeciesSpecificDoma
         return _key_domain_proteins_count;
     }
 
+    @Override
     public int getNumberOfProteinsExhibitingCombinationWith( final DomainId domain_id ) {
         if ( !getCombinableDomainIdToCountsMap().containsKey( domain_id ) ) {
             throw new IllegalArgumentException( "Domain with id " + domain_id + " not found" );
@@ -95,6 +98,7 @@ class PrintableSpeciesSpecificDomainSimilariyData implements SpeciesSpecificDoma
                 .toString();
     }
 
+    @Override
     public StringBuffer toStringBuffer( final DomainSimilarityCalculator.Detailedness detailedness, final boolean html ) {
         final StringBuffer sb = new StringBuffer();
         if ( detailedness == DomainSimilarityCalculator.Detailedness.PUNCTILIOUS ) {
index ecfd1e8..44d5b47 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d61252c..fbcedb6 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -29,6 +29,7 @@ package org.forester.surfacing;
 
 public class ProteinCountsBasedPairwiseDomainSimilarityCalculator implements PairwiseDomainSimilarityCalculator {
 
+    @Override
     public PairwiseDomainSimilarity calculateSimilarity( final CombinableDomains domains_1,
                                                          final CombinableDomains domains_2 ) {
         if ( !domains_1.getKeyDomain().equals( domains_2.getKeyDomain() ) ) {
index afaf661..b1f72cc 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 76d73bf..9200eb8 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -49,6 +49,7 @@ public class SimpleDomain implements Domain {
         throw new RuntimeException( "method not implemented" );
     }
 
+    @Override
     public int compareTo( final Domain domain ) {
         if ( this == domain ) {
             return 0;
@@ -56,10 +57,12 @@ public class SimpleDomain implements Domain {
         return getDomainId().compareTo( domain.getDomainId() );
     }
 
+    @Override
     public DomainId getDomainId() {
         return _id;
     }
 
+    @Override
     public int getFrom() {
         throw new RuntimeException( "method not implemented" );
     }
@@ -73,6 +76,7 @@ public class SimpleDomain implements Domain {
         throw new RuntimeException( "method not implemented" );
     }
 
+    @Override
     public short getNumber() {
         throw new RuntimeException( "method not implemented" );
     }
@@ -92,10 +96,12 @@ public class SimpleDomain implements Domain {
         throw new RuntimeException( "method not implemented" );
     }
 
+    @Override
     public double getPerSequenceEvalue() {
         throw new RuntimeException( "method not implemented" );
     }
 
+    @Override
     public double getPerSequenceScore() {
         throw new RuntimeException( "method not implemented" );
     }
@@ -104,10 +110,12 @@ public class SimpleDomain implements Domain {
         throw new RuntimeException( "method not implemented" );
     }
 
+    @Override
     public int getTo() {
         throw new RuntimeException( "method not implemented" );
     }
 
+    @Override
     public short getTotalCount() {
         throw new RuntimeException( "method not implemented" );
     }
index fb387f6..34fec0c 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 8c5908d..dcfa04c 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 6bfd208..ac29712 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 119d014..a8e966d 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -85,6 +85,7 @@ public final class SurfacingUtil {
     private final static NumberFormat       FORMATTER_3                      = new DecimalFormat( "0.000" );
     private static final Comparator<Domain> ASCENDING_CONFIDENCE_VALUE_ORDER = new Comparator<Domain>() {
 
+                                                                                 @Override
                                                                                  public int compare( final Domain d1,
                                                                                                      final Domain d2 ) {
                                                                                      if ( d1.getPerSequenceEvalue() < d2
@@ -549,12 +550,16 @@ public final class SurfacingUtil {
             SurfacingUtil.writeBinaryStatesMatrixAsListToFile( domain_parsimony.getGainLossMatrix(), null, outfile_name
                     + surfacing_old.PARSIMONY_OUTPUT_FITCH_PRESENT_BC, sep, ForesterUtil.LINE_SEPARATOR, null );
             if ( all_binary_domains_combination_gained_fitch != null ) {
-                collectChangedDomainCombinationsFromBinaryStatesMatrixAsListToFile( domain_parsimony
-                        .getGainLossMatrix(), dc_type, all_binary_domains_combination_gained_fitch, true );
+                collectChangedDomainCombinationsFromBinaryStatesMatrixAsListToFile( domain_parsimony.getGainLossMatrix(),
+                                                                                    dc_type,
+                                                                                    all_binary_domains_combination_gained_fitch,
+                                                                                    true );
             }
             if ( all_binary_domains_combination_lost_fitch != null ) {
-                collectChangedDomainCombinationsFromBinaryStatesMatrixAsListToFile( domain_parsimony
-                        .getGainLossMatrix(), dc_type, all_binary_domains_combination_lost_fitch, false );
+                collectChangedDomainCombinationsFromBinaryStatesMatrixAsListToFile( domain_parsimony.getGainLossMatrix(),
+                                                                                    dc_type,
+                                                                                    all_binary_domains_combination_lost_fitch,
+                                                                                    false );
             }
             if ( output_binary_domain_combinations_for_graphs ) {
                 SurfacingUtil
@@ -644,8 +649,9 @@ public final class SurfacingUtil {
         final String sep = ForesterUtil.LINE_SEPARATOR + "###################" + ForesterUtil.LINE_SEPARATOR;
         final String date_time = ForesterUtil.getCurrentDateTime();
         System.out.println();
-        writeToNexus( outfile_name + surfacing_old.NEXUS_SECONDARY_FEATURES, secondary_features_parsimony
-                .createMatrixOfSecondaryFeaturePresenceOrAbsence( null ), phylogeny );
+        writeToNexus( outfile_name + surfacing_old.NEXUS_SECONDARY_FEATURES,
+                      secondary_features_parsimony.createMatrixOfSecondaryFeaturePresenceOrAbsence( null ),
+                      phylogeny );
         final Phylogeny local_phylogeny_copy = phylogeny.copy();
         secondary_features_parsimony.executeDolloParsimonyOnSecondaryFeatures( mapping_results_map );
         SurfacingUtil.writeMatrixToFile( secondary_features_parsimony.getGainLossMatrix(), outfile_name
@@ -1027,21 +1033,29 @@ public final class SurfacingUtil {
             ForesterUtil.programMessage( surfacing_old.PRG_NAME, "Pfams without mapping to proc. or func. : "
                     + pfams_without_mappings_to_bp_or_mf_counter + " ["
                     + ( 100 * pfams_without_mappings_to_bp_or_mf_counter / all_pfams_encountered.size() ) + "%]" );
-            ForesterUtil.programMessage( surfacing_old.PRG_NAME, "Pfams with a mapping                    : "
-                    + pfams_with_mappings_counter + " ["
-                    + ( 100 * pfams_with_mappings_counter / all_pfams_encountered.size() ) + "%]" );
+            ForesterUtil.programMessage( surfacing_old.PRG_NAME,
+                                         "Pfams with a mapping                    : " + pfams_with_mappings_counter
+                                                 + " ["
+                                                 + ( 100 * pfams_with_mappings_counter / all_pfams_encountered.size() )
+                                                 + "%]" );
             ForesterUtil.programMessage( surfacing_old.PRG_NAME, "Pfams with a mapping to proc. or func.  : "
                     + pfams_with_mappings_to_bp_or_mf_counter + " ["
                     + ( 100 * pfams_with_mappings_to_bp_or_mf_counter / all_pfams_encountered.size() ) + "%]" );
-            ForesterUtil.programMessage( surfacing_old.PRG_NAME, "Pfams with mapping to biological process: "
-                    + biological_process_counter + " ["
-                    + ( 100 * biological_process_counter / all_pfams_encountered.size() ) + "%]" );
-            ForesterUtil.programMessage( surfacing_old.PRG_NAME, "Pfams with mapping to molecular function: "
-                    + molecular_function_counter + " ["
-                    + ( 100 * molecular_function_counter / all_pfams_encountered.size() ) + "%]" );
-            ForesterUtil.programMessage( surfacing_old.PRG_NAME, "Pfams with mapping to cellular component: "
-                    + cellular_component_counter + " ["
-                    + ( 100 * cellular_component_counter / all_pfams_encountered.size() ) + "%]" );
+            ForesterUtil.programMessage( surfacing_old.PRG_NAME,
+                                         "Pfams with mapping to biological process: " + biological_process_counter
+                                                 + " ["
+                                                 + ( 100 * biological_process_counter / all_pfams_encountered.size() )
+                                                 + "%]" );
+            ForesterUtil.programMessage( surfacing_old.PRG_NAME,
+                                         "Pfams with mapping to molecular function: " + molecular_function_counter
+                                                 + " ["
+                                                 + ( 100 * molecular_function_counter / all_pfams_encountered.size() )
+                                                 + "%]" );
+            ForesterUtil.programMessage( surfacing_old.PRG_NAME,
+                                         "Pfams with mapping to cellular component: " + cellular_component_counter
+                                                 + " ["
+                                                 + ( 100 * cellular_component_counter / all_pfams_encountered.size() )
+                                                 + "%]" );
             summary_writer.write( ForesterUtil.LINE_SEPARATOR );
             summary_writer.write( "# Sum of Pfams encountered                : " + all_pfams_encountered.size() );
             summary_writer.write( ForesterUtil.LINE_SEPARATOR );
@@ -1662,8 +1676,7 @@ public final class SurfacingUtil {
             }
             else {
                 per_genome_domain_promiscuity_statistics_writer.write( FORMATTER_3.format( stats
-                        .sampleStandardDeviation() )
-                        + "\t" );
+                        .sampleStandardDeviation() ) + "\t" );
             }
             per_genome_domain_promiscuity_statistics_writer.write( FORMATTER_3.format( stats.median() ) + "\t" );
             per_genome_domain_promiscuity_statistics_writer.write( ( int ) stats.getMin() + "\t" );
@@ -2397,18 +2410,20 @@ public final class SurfacingUtil {
     }
 
     private static void writeToNexus( final String outfile_name, final DomainParsimonyCalculator domain_parsimony ) {
-        writeToNexus( outfile_name + surfacing_old.NEXUS_EXTERNAL_DOMAINS, domain_parsimony
-                .createMatrixOfDomainPresenceOrAbsence() );
-        writeToNexus( outfile_name + surfacing_old.NEXUS_EXTERNAL_DOMAIN_COMBINATIONS, domain_parsimony
-                .createMatrixOfBinaryDomainCombinationPresenceOrAbsence() );
+        writeToNexus( outfile_name + surfacing_old.NEXUS_EXTERNAL_DOMAINS,
+                      domain_parsimony.createMatrixOfDomainPresenceOrAbsence() );
+        writeToNexus( outfile_name + surfacing_old.NEXUS_EXTERNAL_DOMAIN_COMBINATIONS,
+                      domain_parsimony.createMatrixOfBinaryDomainCombinationPresenceOrAbsence() );
     }
 
     private static void writeToNexus( final String outfile_name,
                                       final DomainParsimonyCalculator domain_parsimony,
                                       final Phylogeny phylogeny ) {
-        writeToNexus( outfile_name + surfacing_old.NEXUS_EXTERNAL_DOMAINS, domain_parsimony
-                .createMatrixOfDomainPresenceOrAbsence(), phylogeny );
-        writeToNexus( outfile_name + surfacing_old.NEXUS_EXTERNAL_DOMAIN_COMBINATIONS, domain_parsimony
-                .createMatrixOfBinaryDomainCombinationPresenceOrAbsence(), phylogeny );
+        writeToNexus( outfile_name + surfacing_old.NEXUS_EXTERNAL_DOMAINS,
+                      domain_parsimony.createMatrixOfDomainPresenceOrAbsence(),
+                      phylogeny );
+        writeToNexus( outfile_name + surfacing_old.NEXUS_EXTERNAL_DOMAIN_COMBINATIONS,
+                      domain_parsimony.createMatrixOfBinaryDomainCombinationPresenceOrAbsence(),
+                      phylogeny );
     }
 }
index 678259e..56bb6fa 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d27c23c..8a09ac8 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -73,9 +73,9 @@ import org.forester.phylogeny.data.PhylogenyData;
 import org.forester.phylogeny.data.Polygon;
 import org.forester.phylogeny.data.PropertiesMap;
 import org.forester.phylogeny.data.Property;
+import org.forester.phylogeny.data.Property.AppliesTo;
 import org.forester.phylogeny.data.ProteinDomain;
 import org.forester.phylogeny.data.Taxonomy;
-import org.forester.phylogeny.data.Property.AppliesTo;
 import org.forester.phylogeny.factories.ParserBasedPhylogenyFactory;
 import org.forester.phylogeny.factories.PhylogenyFactory;
 import org.forester.phylogeny.iterators.PhylogenyNodeIterator;
index 7fc7c90..1a9d85e 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 086e51a..ebc1a6a 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -96,13 +96,15 @@ public final class PhylogenyDecorator {
                         if ( new_values.containsKey( TP_TAXONOMY_ID )
                                 && new_values.containsKey( TP_TAXONOMY_ID_PROVIDER ) ) {
                             ForesterUtil.ensurePresenceOfTaxonomy( node );
-                            node.getNodeData().getTaxonomy().setIdentifier( new Identifier( new_values
-                                    .get( TP_TAXONOMY_ID ), new_values.get( TP_TAXONOMY_ID_PROVIDER ) ) );
+                            node.getNodeData()
+                                    .getTaxonomy()
+                                    .setIdentifier( new Identifier( new_values.get( TP_TAXONOMY_ID ),
+                                                                    new_values.get( TP_TAXONOMY_ID_PROVIDER ) ) );
                         }
                         else if ( new_values.containsKey( TP_TAXONOMY_ID ) ) {
                             ForesterUtil.ensurePresenceOfTaxonomy( node );
-                            node.getNodeData().getTaxonomy().setIdentifier( new Identifier( new_values
-                                    .get( TP_TAXONOMY_ID ) ) );
+                            node.getNodeData().getTaxonomy()
+                                    .setIdentifier( new Identifier( new_values.get( TP_TAXONOMY_ID ) ) );
                         }
                         if ( new_values.containsKey( TP_TAXONOMY_SN ) ) {
                             ForesterUtil.ensurePresenceOfTaxonomy( node );
@@ -119,8 +121,10 @@ public final class PhylogenyDecorator {
                         if ( new_values.containsKey( TP_SEQ_ACCESSION )
                                 && new_values.containsKey( TP_SEQ_ACCESSION_SOURCE ) ) {
                             ForesterUtil.ensurePresenceOfSequence( node );
-                            node.getNodeData().getSequence().setAccession( new Accession( new_values
-                                    .get( TP_SEQ_ACCESSION ), new_values.get( TP_SEQ_ACCESSION_SOURCE ) ) );
+                            node.getNodeData()
+                                    .getSequence()
+                                    .setAccession( new Accession( new_values.get( TP_SEQ_ACCESSION ),
+                                                                  new_values.get( TP_SEQ_ACCESSION_SOURCE ) ) );
                         }
                         if ( new_values.containsKey( TP_SEQ_ANNOTATION_DESC ) ) {
                             ForesterUtil.ensurePresenceOfSequence( node );
index a3c7fa8..0014915 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d1e015b..29bd2dd 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 07d3da8..3d295cf 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 699526f..8ec95e7 100644 (file)
@@ -7,7 +7,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -17,7 +17,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -47,6 +47,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#addValue(double)
      */
+    @Override
     public void addValue( final double d ) {
         _recalc_sigma = true;
         _sum += d;
@@ -62,6 +63,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#arithmeticMean()
      */
+    @Override
     public double arithmeticMean() {
         validate();
         return getSum() / getN();
@@ -70,6 +72,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#asSummary()
      */
+    @Override
     public String asSummary() {
         if ( getN() > 1 ) {
             return arithmeticMean() + DescriptiveStatistics.PLUS_MINUS + sampleStandardDeviation() + " [" + getMin()
@@ -83,6 +86,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#coefficientOfVariation()
      */
+    @Override
     public double coefficientOfVariation() {
         validate();
         return ( sampleStandardDeviation() / arithmeticMean() );
@@ -91,6 +95,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#getDataAsDoubleArray()
      */
+    @Override
     public double[] getDataAsDoubleArray() {
         validate();
         final double[] data_array = new double[ getN() ];
@@ -103,6 +108,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#getMax()
      */
+    @Override
     public double getMax() {
         validate();
         return _max;
@@ -111,6 +117,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#getMin()
      */
+    @Override
     public double getMin() {
         validate();
         return _min;
@@ -119,6 +126,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#getN()
      */
+    @Override
     public int getN() {
         return _data.size();
     }
@@ -126,6 +134,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#getSum()
      */
+    @Override
     public double getSum() {
         validate();
         return _sum;
@@ -134,6 +143,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#getSummaryAsString()
      */
+    @Override
     public String getSummaryAsString() {
         validate();
         final double mean = arithmeticMean();
@@ -144,6 +154,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#getValue(int)
      */
+    @Override
     public double getValue( final int index ) {
         validate();
         return ( ( ( _data.get( index ) ) ).doubleValue() );
@@ -161,6 +172,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#median()
      */
+    @Override
     public double median() {
         validate();
         double median = 0.0;
@@ -185,6 +197,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#midrange()
      */
+    @Override
     public double midrange() {
         validate();
         return ( _min + _max ) / 2.0;
@@ -193,6 +206,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#pearsonianSkewness()
      */
+    @Override
     public double pearsonianSkewness() {
         validate();
         final double mean = arithmeticMean();
@@ -204,6 +218,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#sampleStandardDeviation()
      */
+    @Override
     public double sampleStandardDeviation() {
         return Math.sqrt( sampleVariance() );
     }
@@ -211,6 +226,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#sampleStandardUnit(double)
      */
+    @Override
     public double sampleStandardUnit( final double value ) {
         validate();
         return BasicDescriptiveStatistics.sampleStandardUnit( value, arithmeticMean(), sampleStandardDeviation() );
@@ -219,6 +235,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#sampleVariance()
      */
+    @Override
     public double sampleVariance() {
         validate();
         if ( getN() < 2 ) {
@@ -230,6 +247,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#standardErrorOfMean()
      */
+    @Override
     public double standardErrorOfMean() {
         validate();
         return ( sampleStandardDeviation() / Math.sqrt( getN() ) );
@@ -238,6 +256,7 @@ public class BasicDescriptiveStatistics implements DescriptiveStatistics {
     /* (non-Javadoc)
      * @see org.forester.util.DescriptiveStatisticsI#sumDeviations()
      */
+    @Override
     public double sumDeviations() {
         validate();
         if ( _recalc_sigma ) {
index 2469129..6f6d0a8 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 9ebae2b..8ab9622 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 0fc0485..e3b9276 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 054f12c..645a6cd 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 83b2f4f..f5a8a7f 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -79,5 +79,6 @@ public interface DescriptiveStatistics {
 
     public abstract double sumDeviations();
 
+    @Override
     public abstract String toString();
 }
\ No newline at end of file
index 54aafe8..7a76b6b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d297377..cad5191 100644 (file)
@@ -6,7 +6,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -16,7 +16,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 3edec56..7fd5c84 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2000-2009 Christian M. Zmasek
 // Copyright (C) 2007-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index ada203b..957480b 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
@@ -64,12 +64,14 @@ import org.forester.io.parsers.PhylogenyParser;
 import org.forester.io.parsers.nexus.NexusPhylogeniesParser;
 import org.forester.io.parsers.nhx.NHXParser;
 import org.forester.io.parsers.phyloxml.PhyloXmlParser;
+import org.forester.io.parsers.phyloxml.PhyloXmlUtil;
 import org.forester.io.parsers.tol.TolParser;
 import org.forester.phylogeny.Phylogeny;
 import org.forester.phylogeny.PhylogenyMethods;
 import org.forester.phylogeny.PhylogenyNode;
 import org.forester.phylogeny.data.Confidence;
 import org.forester.phylogeny.data.Distribution;
+import org.forester.phylogeny.data.Identifier;
 import org.forester.phylogeny.data.Sequence;
 import org.forester.phylogeny.data.Taxonomy;
 import org.forester.phylogeny.iterators.PhylogenyNodeIterator;
@@ -1173,6 +1175,38 @@ public final class ForesterUtil {
                         }
                         n.getNodeData().getSequence().setName( name );
                         break;
+                    case TAXONOMY_ID_UNIPROT_1: {
+                        if ( !n.getNodeData().isHasTaxonomy() ) {
+                            n.getNodeData().setTaxonomy( new Taxonomy() );
+                        }
+                        String id = name;
+                        final int i = name.indexOf( '_' );
+                        if ( i > 0 ) {
+                            id = name.substring( i, name.length() );
+                        }
+                        else {
+                            n.setName( "" );
+                        }
+                        n.getNodeData().getTaxonomy()
+                                .setIdentifier( new Identifier( id, PhyloXmlUtil.UNIPROT_TAX_PROVIDER ) );
+                        break;
+                    }
+                    case TAXONOMY_ID_UNIPROT_2: {
+                        if ( !n.getNodeData().isHasTaxonomy() ) {
+                            n.getNodeData().setTaxonomy( new Taxonomy() );
+                        }
+                        String id = name;
+                        final int i = name.indexOf( '_' );
+                        if ( i > 0 ) {
+                            id = name.substring( 0, i );
+                        }
+                        else {
+                            n.setName( "" );
+                        }
+                        n.getNodeData().getTaxonomy()
+                                .setIdentifier( new Identifier( id, PhyloXmlUtil.UNIPROT_TAX_PROVIDER ) );
+                        break;
+                    }
                 }
             }
         }
@@ -1236,7 +1270,14 @@ public final class ForesterUtil {
     }
 
     public static enum PhylogenyNodeField {
-        CLADE_NAME, TAXONOMY_CODE, TAXONOMY_SCIENTIFIC_NAME, TAXONOMY_COMMON_NAME, SEQUENCE_SYMBOL, SEQUENCE_NAME;
+        CLADE_NAME,
+        TAXONOMY_CODE,
+        TAXONOMY_SCIENTIFIC_NAME,
+        TAXONOMY_COMMON_NAME,
+        SEQUENCE_SYMBOL,
+        SEQUENCE_NAME,
+        TAXONOMY_ID_UNIPROT_1,
+        TAXONOMY_ID_UNIPROT_2;
     }
 
     public static enum TAXONOMY_EXTRACTION {
index 7b0a655..a00c914 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 7b3704b..437d548 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2008-2009 Christian M. Zmasek
 // Copyright (C) 2008-2009 Burnham Institute for Medical Research
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b62906d..9fa599f 100644 (file)
@@ -13,7 +13,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index d4b0b75..6a1ec5a 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index 623f837..1ecf5ea 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index b4f723d..fe4a8ee 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index ed3bc29..e4a5b25 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
index c9445f4..c1a2e79 100644 (file)
@@ -5,7 +5,7 @@
 // Copyright (C) 2010 Christian M Zmasek
 // Copyright (C) 2010 Sanford-Burnham Medical Research Institute
 // All rights reserved
-// 
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
@@ -15,7 +15,7 @@
 // but WITHOUT ANY WARRANTY; without even the implied warranty of
 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
 // Lesser General Public License for more details.
-// 
+//
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA