From: cmzmasek Date: Mon, 4 Jun 2012 18:44:14 +0000 (+0000) Subject: in progress X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=8e37534c03f75befdad0d75fbf8e05be11cde71a;p=jalview.git in progress --- diff --git a/forester/java/src/org/forester/application/confadd.java b/forester/java/src/org/forester/application/confadd.java index 4b6b526..db01fd4 100644 --- a/forester/java/src/org/forester/application/confadd.java +++ b/forester/java/src/org/forester/application/confadd.java @@ -59,7 +59,8 @@ public class confadd { final static private String WWW = "www.phylosoft.org/forester/"; public static void main( final String args[] ) { - ForesterUtil.printProgramInformation( PRG_NAME, PRG_VERSION, PRG_DATE, E_MAIL, WWW ); + ForesterUtil.printProgramInformation( PRG_NAME, null, PRG_VERSION, PRG_DATE, E_MAIL, WWW, ForesterUtil.getForesterLibraryInformation() ); + CommandLineArguments cla = null; try { cla = new CommandLineArguments( args ); diff --git a/forester/java/src/org/forester/application/count_support.java b/forester/java/src/org/forester/application/count_support.java index 3df54ba..96a7596 100644 --- a/forester/java/src/org/forester/application/count_support.java +++ b/forester/java/src/org/forester/application/count_support.java @@ -50,11 +50,13 @@ public class count_support { final static private String PRG_NAME = "count_support"; final static private String PRG_VERSION = "1.0"; final static private String PRG_DATE = "2008.03.04"; + final static private String E_MAIL = "phylosoft@gmail.com"; + final static private String WWW = "www.phylosoft.org/forester/"; private final static boolean WRITE_EVALUATORS_AS_NHX = false; public static void main( final String args[] ) { - ForesterUtil - .printProgramInformation( count_support.PRG_NAME, count_support.PRG_VERSION, count_support.PRG_DATE ); + ForesterUtil.printProgramInformation( PRG_NAME, null, PRG_VERSION, PRG_DATE, E_MAIL, WWW, ForesterUtil.getForesterLibraryInformation() ); + if ( ( args.length < 3 ) || ( args.length > 7 ) ) { System.out.println(); System.out.println( count_support.PRG_NAME + ": wrong number of arguments" ); diff --git a/forester/java/src/org/forester/application/mcc.java b/forester/java/src/org/forester/application/mcc.java index 77c9a7f..e31679a 100644 --- a/forester/java/src/org/forester/application/mcc.java +++ b/forester/java/src/org/forester/application/mcc.java @@ -90,7 +90,7 @@ public class mcc { } private static void printHelp() { - ForesterUtil.printProgramInformation( PRG_NAME, PRG_DESC, PRG_VERSION, PRG_DATE, E_MAIL, WWW ); + ForesterUtil.printProgramInformation( PRG_NAME, PRG_DESC, PRG_VERSION, PRG_DATE, E_MAIL, WWW, ForesterUtil.getForesterLibraryInformation() ); System.out.println( "Usage:" ); System.out.println(); System.out.println( PRG_NAME + " " ); diff --git a/forester/java/src/org/forester/archaeopteryx/MainFrame.java b/forester/java/src/org/forester/archaeopteryx/MainFrame.java index 35ba34a..26600d9 100644 --- a/forester/java/src/org/forester/archaeopteryx/MainFrame.java +++ b/forester/java/src/org/forester/archaeopteryx/MainFrame.java @@ -1150,10 +1150,11 @@ public abstract class MainFrame extends JFrame implements ActionListener { */ static void about() { final StringBuffer about = new StringBuffer( "Archaeopteryx\nVersion " + Constants.VERSION + "\n" ); - about.append( "Copyright (C) 2007-2011 Christian Zmasek\n" ); + about.append( "Copyright (C) 2007-2012 Christian M. Zmasek\n" ); about.append( "All Rights Reserved\n" ); about.append( "License: GNU Lesser General Public License (LGPL)\n" ); about.append( "Last modified: " + Constants.PRG_DATE + "\n" ); + about.append( "Based on: " + ForesterUtil.getForesterLibraryInformation() + "\n" ); about.append( "phyloXML version : " + ForesterConstants.PHYLO_XML_VERSION + "\n" ); about.append( "phyloXML location: " + ForesterConstants.PHYLO_XML_LOCATION + "\n" ); if ( !ForesterUtil.isEmpty( ForesterUtil.JAVA_VERSION ) && !ForesterUtil.isEmpty( ForesterUtil.JAVA_VENDOR ) ) { diff --git a/forester/java/src/org/forester/util/ForesterConstants.java b/forester/java/src/org/forester/util/ForesterConstants.java index 9899fd7..0b75065 100644 --- a/forester/java/src/org/forester/util/ForesterConstants.java +++ b/forester/java/src/org/forester/util/ForesterConstants.java @@ -27,6 +27,9 @@ package org.forester.util; public final class ForesterConstants { + public final static String FORESTER_VERSION = "1.000"; + public final static String FORESTER_DATE = "120604"; + public final static String PHYLO_XML_VERSION = "1.10"; public final static String PHYLO_XML_LOCATION = "http://www.phyloxml.org"; public final static String PHYLO_XML_XSD = "phyloxml.xsd"; @@ -36,6 +39,7 @@ public final class ForesterConstants { public final static String UTF8 = "UTF-8"; public final static String PHYLO_XML_REFERENCE = "Han MV and Zmasek CM (2009): \"phyloXML: XML for evolutionary biology and comparative genomics\", BMC Bioinformatics 10:356"; public final static boolean RELEASE = false; + public enum PhylogeneticTreeFormats { NH, NHX, NEXUS, PHYLOXML diff --git a/forester/java/src/org/forester/util/ForesterUtil.java b/forester/java/src/org/forester/util/ForesterUtil.java index fcc7278..1c914c8 100644 --- a/forester/java/src/org/forester/util/ForesterUtil.java +++ b/forester/java/src/org/forester/util/ForesterUtil.java @@ -95,6 +95,10 @@ public final class ForesterUtil { sb.append( separator ); } } + + final public static String getForesterLibraryInformation() { + return "forester " + ForesterConstants.FORESTER_VERSION + " (" + ForesterConstants.FORESTER_DATE + ")"; + } public static boolean seqIsLikelyToBeAa( final String s ) { final String seq = s.toLowerCase(); @@ -735,7 +739,8 @@ public final class ForesterUtil { final String prg_version, final String date, final String email, - final String www ) { + final String www, + final String based_on ) { String my_prg_name = new String( prg_name ); if ( !ForesterUtil.isEmpty( desc ) ) { my_prg_name += ( " - " + desc ); @@ -748,8 +753,11 @@ public final class ForesterUtil { } System.out.println(); System.out.println(); - System.out.println( "WWW : " + www ); - System.out.println( "Contact: " + email ); + System.out.println( "WWW : " + www ); + System.out.println( "Contact : " + email ); + if ( !ForesterUtil.isEmpty( based_on ) ) { + System.out.println( "Based on: " + based_on ); + } if ( !ForesterUtil.isEmpty( ForesterUtil.JAVA_VERSION ) && !ForesterUtil.isEmpty( ForesterUtil.JAVA_VENDOR ) ) { System.out.println(); System.out.println( "[running on Java " + ForesterUtil.JAVA_VERSION + " " + ForesterUtil.JAVA_VENDOR + "]" ); @@ -762,7 +770,7 @@ public final class ForesterUtil { final String date, final String email, final String www ) { - printProgramInformation( prg_name, null, prg_version, date, email, www ); + printProgramInformation( prg_name, null, prg_version, date, email, www, null ); } final public static void printWarningMessage( final String prg_name, final String message ) {