|
From: <yo...@us...> - 2010-02-24 16:11:47
|
Revision: 517
http://treebase.svn.sourceforge.net/treebase/?rev=517&view=rev
Author: youjun
Date: 2010-02-24 14:53:46 +0000 (Wed, 24 Feb 2010)
Log Message:
-----------
add new algorithm option classes, update jsp page accordingly
Modified Paths:
--------------
trunk/treebase-core/src/main/java/org/cipres/treebase/auxdata/CommitStudy.java
trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/Algorithm.java
trunk/treebase-core/src/main/resources/hibernate.cfg.xml
trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java
trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DisplayAnalysisController.java
trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchSummaryController.java
trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SummaryController.java
trunk/treebase-web/src/main/java/org/cipres/treebase/web/listeners/StartupListener.java
trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/AnalysisStepCommand.java
trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/ControllerUtil.java
trunk/treebase-web/src/main/webapp/WEB-INF/pages/submissionSummaryView.jsp
Added Paths:
-----------
trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/BayesianAlgorithm.java
trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/EvolutionAlgorithm.java
trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/JoiningAlgorithm.java
trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/UPGMAAlgorithm.java
Removed Paths:
-------------
trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/DistanceAlgorithm.java
Modified: trunk/treebase-core/src/main/java/org/cipres/treebase/auxdata/CommitStudy.java
===================================================================
--- trunk/treebase-core/src/main/java/org/cipres/treebase/auxdata/CommitStudy.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-core/src/main/java/org/cipres/treebase/auxdata/CommitStudy.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -18,7 +18,10 @@
import org.cipres.treebase.domain.study.AnalyzedMatrix;
import org.cipres.treebase.domain.study.AnalyzedTree;
import org.cipres.treebase.domain.study.Citation;
-import org.cipres.treebase.domain.study.DistanceAlgorithm;
+import org.cipres.treebase.domain.study.BayesianAlgorithm;
+import org.cipres.treebase.domain.study.EvolutionAlgorithm;
+import org.cipres.treebase.domain.study.JoiningAlgorithm;
+import org.cipres.treebase.domain.study.UPGMAAlgorithm;
import org.cipres.treebase.domain.study.LikelihoodAlgorithm;
import org.cipres.treebase.domain.study.OtherAlgorithm;
import org.cipres.treebase.domain.study.ParsimonyAlgorithm;
@@ -222,11 +225,16 @@
Algorithm theAlgorithm;
String tb1Algorithm = an.getString("algorithm");
-
if (tb1Algorithm.equalsIgnoreCase("parsimony")) {
theAlgorithm = new ParsimonyAlgorithm();
- } else if (tb1Algorithm.equalsIgnoreCase("distance")) {
- theAlgorithm = new DistanceAlgorithm();
+ } else if (tb1Algorithm.equalsIgnoreCase("bayesian")) {
+ theAlgorithm = new BayesianAlgorithm();
+ } else if (tb1Algorithm.equalsIgnoreCase("evolution")) {
+ theAlgorithm = new EvolutionAlgorithm();
+ } else if (tb1Algorithm.equalsIgnoreCase("joining")) {
+ theAlgorithm = new JoiningAlgorithm();
+ } else if (tb1Algorithm.equalsIgnoreCase("UPGMA")) {
+ theAlgorithm = new UPGMAAlgorithm();
} else if (tb1Algorithm.equalsIgnoreCase("likelihood")) {
theAlgorithm = new LikelihoodAlgorithm();
} else {
Modified: trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/Algorithm.java
===================================================================
--- trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/Algorithm.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/Algorithm.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -98,11 +98,15 @@
}
/* constants returned by getAlgorithmType */
- public static final String LikelihoodAlgorithm = "maximum likelihood";
- public static final String DistanceAlgorithm = "distance";
+ public static final String LikelihoodAlgorithm = "maximum likelihood";
public static final String OtherAlgorithm = "other algorithm";
public static final String ParsimonyAlgorithm = "parsimony";
+ public static final String BayesianAlgorithm ="bayesian inference";
+ public static final String EvolutionAlgorithm ="minimum evolution";
+ public static final String JoiningAlgorithm ="neighbor joining";
+ public static final String UPGMAAlgorithm = "UPGMA";
+
/**
* @return a string describing the algorithm type (for example, "parsimony")
* @author mjd 20080723
Added: trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/BayesianAlgorithm.java
===================================================================
--- trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/BayesianAlgorithm.java (rev 0)
+++ trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/BayesianAlgorithm.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -0,0 +1,33 @@
+package org.cipres.treebase.domain.study;
+
+import javax.persistence.DiscriminatorValue;
+import javax.persistence.Entity;
+import javax.persistence.Transient;
+
+/**
+ * UPGMAAlgorithm.java
+ *
+ * Created on Feb 23, 2010
+ *
+ * @author Youjun Guo
+ *
+ */
+@SuppressWarnings("serial")
+@Entity
+@DiscriminatorValue("B")
+
+public class BayesianAlgorithm extends Algorithm{
+ /**
+ * Constructor.
+ */
+ public BayesianAlgorithm() {
+ super();
+ }
+
+ @Override
+ @Transient
+ public String getAlgorithmType() {
+ return BayesianAlgorithm;
+ }
+
+}
Deleted: trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/DistanceAlgorithm.java
===================================================================
--- trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/DistanceAlgorithm.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/DistanceAlgorithm.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -1,33 +0,0 @@
-package org.cipres.treebase.domain.study;
-
-import javax.persistence.DiscriminatorValue;
-import javax.persistence.Entity;
-import javax.persistence.Transient;
-
-/**
- * DistanceAlgorithm.java
- *
- * Created on Mar 13, 2006
- *
- * @author Jin Ruan
- *
- */
-@SuppressWarnings("serial")
-@Entity
-@DiscriminatorValue("D")
-public class DistanceAlgorithm extends Algorithm {
-
- /**
- * Constructor.
- */
- public DistanceAlgorithm() {
- super();
- }
-
- @Override
- @Transient
- public String getAlgorithmType() {
- return DistanceAlgorithm;
- }
-
-}
Added: trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/EvolutionAlgorithm.java
===================================================================
--- trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/EvolutionAlgorithm.java (rev 0)
+++ trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/EvolutionAlgorithm.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -0,0 +1,33 @@
+package org.cipres.treebase.domain.study;
+
+import javax.persistence.DiscriminatorValue;
+import javax.persistence.Entity;
+import javax.persistence.Transient;
+
+/**
+ * UPGMAAlgorithm.java
+ *
+ * Created on Feb 23, 2010
+ *
+ * @author Youjun Guo
+ *
+ */
+@SuppressWarnings("serial")
+@Entity
+@DiscriminatorValue("E")
+
+public class EvolutionAlgorithm extends Algorithm {
+ /**
+ * Constructor.
+ */
+ public EvolutionAlgorithm() {
+ super();
+ }
+
+ @Override
+ @Transient
+ public String getAlgorithmType() {
+ return EvolutionAlgorithm;
+ }
+
+}
Added: trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/JoiningAlgorithm.java
===================================================================
--- trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/JoiningAlgorithm.java (rev 0)
+++ trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/JoiningAlgorithm.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -0,0 +1,33 @@
+package org.cipres.treebase.domain.study;
+
+import javax.persistence.DiscriminatorValue;
+import javax.persistence.Entity;
+import javax.persistence.Transient;
+
+/**
+ * UPGMAAlgorithm.java
+ *
+ * Created on Feb 23, 2010
+ *
+ * @author Youjun Guo
+ *
+ */
+@SuppressWarnings("serial")
+@Entity
+@DiscriminatorValue("J")
+
+public class JoiningAlgorithm extends Algorithm {
+ /**
+ * Constructor.
+ */
+ public JoiningAlgorithm() {
+ super();
+ }
+
+ @Override
+ @Transient
+ public String getAlgorithmType() {
+ return JoiningAlgorithm;
+ }
+
+}
Copied: trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/UPGMAAlgorithm.java (from rev 516, trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/DistanceAlgorithm.java)
===================================================================
--- trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/UPGMAAlgorithm.java (rev 0)
+++ trunk/treebase-core/src/main/java/org/cipres/treebase/domain/study/UPGMAAlgorithm.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -0,0 +1,33 @@
+package org.cipres.treebase.domain.study;
+
+import javax.persistence.DiscriminatorValue;
+import javax.persistence.Entity;
+import javax.persistence.Transient;
+
+/**
+ * UPGMAAlgorithm.java
+ *
+ * Created on Feb 23, 2010
+ *
+ * @author Youjun Guo
+ *
+ */
+@SuppressWarnings("serial")
+@Entity
+@DiscriminatorValue("U")
+public class UPGMAAlgorithm extends Algorithm {
+
+ /**
+ * Constructor.
+ */
+ public UPGMAAlgorithm() {
+ super();
+ }
+
+ @Override
+ @Transient
+ public String getAlgorithmType() {
+ return UPGMAAlgorithm;
+ }
+
+}
Modified: trunk/treebase-core/src/main/resources/hibernate.cfg.xml
===================================================================
--- trunk/treebase-core/src/main/resources/hibernate.cfg.xml 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-core/src/main/resources/hibernate.cfg.xml 2010-02-24 14:53:46 UTC (rev 517)
@@ -104,8 +104,10 @@
<mapping class="org.cipres.treebase.domain.study.BookCitation" />
<mapping class="org.cipres.treebase.domain.study.Citation" />
<mapping class="org.cipres.treebase.domain.study.CitationStatus" />
- <mapping class="org.cipres.treebase.domain.study.DistanceAlgorithm" />
+ <mapping class="org.cipres.treebase.domain.study.BayesianAlgorithm" />
+ <mapping class="org.cipres.treebase.domain.study.EvolutionAlgorithm" />
<mapping class="org.cipres.treebase.domain.study.InBookCitation" />
+ <mapping class="org.cipres.treebase.domain.study.JoiningAlgorithm" />
<mapping class="org.cipres.treebase.domain.study.LikelihoodAlgorithm" />
<mapping class="org.cipres.treebase.domain.study.OtherAlgorithm" />
<mapping class="org.cipres.treebase.domain.study.ParsimonyAlgorithm" />
@@ -113,7 +115,8 @@
<mapping class="org.cipres.treebase.domain.study.Study" />
<mapping class="org.cipres.treebase.domain.study.StudyStatus" />
<mapping class="org.cipres.treebase.domain.study.Submission" />
-
+ <mapping class="org.cipres.treebase.domain.study.UPGMAAlgorithm" />
+
<mapping class="org.cipres.treebase.domain.taxon.LSIDTaxonLink" />
<mapping class="org.cipres.treebase.domain.taxon.SpecimenLabel" />
<mapping class="org.cipres.treebase.domain.taxon.Taxon" />
Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java
===================================================================
--- trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -77,9 +77,13 @@
public static final String ALGORITHM_TYPES = "algorithmtypes";
public static final String ALGORITHM_LIKELIHOOD = Algorithm.LikelihoodAlgorithm;
public static final String ALGORITHM_PARSIMONY = Algorithm.ParsimonyAlgorithm;
- public static final String ALGORITHM_DISTANCE = Algorithm.DistanceAlgorithm;
+ //public static final String ALGORITHM_DISTANCE = Algorithm.DistanceAlgorithm;
public static final String ALGORITHM_OTHER = Algorithm.OtherAlgorithm;
-
+ public static final String ALGORITHM_Bayesian =Algorithm.BayesianAlgorithm;
+ public static final String ALGORITHM_Evolution =Algorithm.EvolutionAlgorithm;
+ public static final String ALGORITHM_Joining =Algorithm.JoiningAlgorithm;
+ public static final String ALGORITHM_UPGMA = Algorithm.UPGMAAlgorithm;
+
public static final String SEARCH_COMMAND = "searchCommand";
public static final String MATRIX_KEY = "matrix";
Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DisplayAnalysisController.java
===================================================================
--- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DisplayAnalysisController.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DisplayAnalysisController.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -19,13 +19,16 @@
import org.cipres.treebase.domain.study.AnalyzedData;
import org.cipres.treebase.domain.study.AnalyzedMatrix;
import org.cipres.treebase.domain.study.AnalyzedTree;
-import org.cipres.treebase.domain.study.DistanceAlgorithm;
+import org.cipres.treebase.domain.study.BayesianAlgorithm;
+import org.cipres.treebase.domain.study.EvolutionAlgorithm;
+import org.cipres.treebase.domain.study.JoiningAlgorithm;
import org.cipres.treebase.domain.study.LikelihoodAlgorithm;
import org.cipres.treebase.domain.study.OtherAlgorithm;
import org.cipres.treebase.domain.study.ParsimonyAlgorithm;
import org.cipres.treebase.domain.study.Study;
import org.cipres.treebase.domain.study.StudyService;
import org.cipres.treebase.domain.study.Submission;
+import org.cipres.treebase.domain.study.UPGMAAlgorithm;
import org.cipres.treebase.framework.ExecutionResult;
import org.cipres.treebase.web.Constants;
import org.cipres.treebase.web.model.AnalysisCommand;
@@ -128,11 +131,17 @@
algorithmType = Constants.ALGORITHM_LIKELIHOOD;
} else if (algorithm instanceof ParsimonyAlgorithm) {
algorithmType = Constants.ALGORITHM_PARSIMONY;
- } else if (algorithm instanceof DistanceAlgorithm) {
- algorithmType = Constants.ALGORITHM_DISTANCE;
- } else if (algorithm instanceof OtherAlgorithm) {
+ } else if (algorithm instanceof OtherAlgorithm) {
algorithmType = Constants.ALGORITHM_OTHER;
- }
+ }else if (algorithm instanceof BayesianAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Bayesian;
+ } else if (algorithm instanceof EvolutionAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Evolution;
+ } else if (algorithm instanceof JoiningAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Joining;
+ } else if (algorithm instanceof UPGMAAlgorithm) {
+ algorithmType = Constants.ALGORITHM_UPGMA;
+ }
// add algorithm type for analysisStepCommand
analysisStepCommand.setAlgorithmType(algorithmType);
Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchSummaryController.java
===================================================================
--- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchSummaryController.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchSummaryController.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -27,13 +27,16 @@
import org.cipres.treebase.domain.study.AnalyzedData;
import org.cipres.treebase.domain.study.AnalyzedMatrix;
import org.cipres.treebase.domain.study.AnalyzedTree;
-import org.cipres.treebase.domain.study.DistanceAlgorithm;
+import org.cipres.treebase.domain.study.BayesianAlgorithm;
+import org.cipres.treebase.domain.study.EvolutionAlgorithm;
+import org.cipres.treebase.domain.study.JoiningAlgorithm;
import org.cipres.treebase.domain.study.LikelihoodAlgorithm;
import org.cipres.treebase.domain.study.OtherAlgorithm;
import org.cipres.treebase.domain.study.ParsimonyAlgorithm;
import org.cipres.treebase.domain.study.Study;
import org.cipres.treebase.domain.study.StudyService;
import org.cipres.treebase.domain.study.Submission;
+import org.cipres.treebase.domain.study.UPGMAAlgorithm;
import org.cipres.treebase.domain.taxon.Taxon;
import org.cipres.treebase.domain.taxon.TaxonLabel;
import org.cipres.treebase.domain.taxon.TaxonLabelService;
@@ -197,11 +200,19 @@
algorithmType = Constants.ALGORITHM_LIKELIHOOD;
} else if (algorithm instanceof ParsimonyAlgorithm) {
algorithmType = Constants.ALGORITHM_PARSIMONY;
- } else if (algorithm instanceof DistanceAlgorithm) {
- algorithmType = Constants.ALGORITHM_DISTANCE;
- } else if (algorithm instanceof OtherAlgorithm) {
+ }else if (algorithm instanceof OtherAlgorithm) {
algorithmType = Constants.ALGORITHM_OTHER;
- }
+ }else if (algorithm instanceof BayesianAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Bayesian;
+ } else if (algorithm instanceof EvolutionAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Evolution;
+ } else if (algorithm instanceof JoiningAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Joining;
+ } else if (algorithm instanceof UPGMAAlgorithm) {
+ algorithmType = Constants.ALGORITHM_UPGMA;
+ }
+
+
// add algorithm type for analysisStepCommand
analysisStepCommand.setAlgorithmType(algorithmType);
@@ -336,11 +347,18 @@
algorithmType = Constants.ALGORITHM_LIKELIHOOD;
} else if (algorithm instanceof ParsimonyAlgorithm) {
algorithmType = Constants.ALGORITHM_PARSIMONY;
- } else if (algorithm instanceof DistanceAlgorithm) {
- algorithmType = Constants.ALGORITHM_DISTANCE;
- } else if (algorithm instanceof OtherAlgorithm) {
+ }else if (algorithm instanceof OtherAlgorithm) {
algorithmType = Constants.ALGORITHM_OTHER;
- }
+ }else if (algorithm instanceof BayesianAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Bayesian;
+ }else if (algorithm instanceof EvolutionAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Evolution;
+ }else if (algorithm instanceof JoiningAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Joining;
+ }else if (algorithm instanceof UPGMAAlgorithm) {
+ algorithmType = Constants.ALGORITHM_UPGMA;
+ }
+
// add algorithm type for analysisStepCommand
analysisStepCommand.setAlgorithmType(algorithmType);
Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SummaryController.java
===================================================================
--- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SummaryController.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SummaryController.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -26,8 +26,10 @@
import org.cipres.treebase.domain.study.AnalyzedMatrix;
import org.cipres.treebase.domain.study.AnalyzedTree;
import org.cipres.treebase.domain.study.ArticleCitation;
+import org.cipres.treebase.domain.study.BayesianAlgorithm;
import org.cipres.treebase.domain.study.Citation;
-import org.cipres.treebase.domain.study.DistanceAlgorithm;
+import org.cipres.treebase.domain.study.EvolutionAlgorithm;
+import org.cipres.treebase.domain.study.JoiningAlgorithm;
import org.cipres.treebase.domain.study.LikelihoodAlgorithm;
import org.cipres.treebase.domain.study.OtherAlgorithm;
import org.cipres.treebase.domain.study.ParsimonyAlgorithm;
@@ -35,6 +37,7 @@
import org.cipres.treebase.domain.study.StudyService;
import org.cipres.treebase.domain.study.Submission;
import org.cipres.treebase.domain.study.SubmissionService;
+import org.cipres.treebase.domain.study.UPGMAAlgorithm;
import org.cipres.treebase.web.Constants;
import org.cipres.treebase.web.model.AnalysisCommand;
import org.cipres.treebase.web.model.AnalysisStepCommand;
@@ -212,11 +215,18 @@
algorithmType = Constants.ALGORITHM_LIKELIHOOD;
} else if (algorithm instanceof ParsimonyAlgorithm) {
algorithmType = Constants.ALGORITHM_PARSIMONY;
- } else if (algorithm instanceof DistanceAlgorithm) {
- algorithmType = Constants.ALGORITHM_DISTANCE;
} else if (algorithm instanceof OtherAlgorithm) {
algorithmType = Constants.ALGORITHM_OTHER;
- }
+ }else if (algorithm instanceof BayesianAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Bayesian;
+ } else if (algorithm instanceof EvolutionAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Evolution;
+ } else if (algorithm instanceof JoiningAlgorithm) {
+ algorithmType = Constants.ALGORITHM_Joining;
+ } else if (algorithm instanceof UPGMAAlgorithm) {
+ algorithmType = Constants.ALGORITHM_UPGMA;
+ }
+
// add algorithm type for analysisStepCommand
analysisStepCommand.setAlgorithmType(algorithmType);
Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/listeners/StartupListener.java
===================================================================
--- trunk/treebase-web/src/main/java/org/cipres/treebase/web/listeners/StartupListener.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/listeners/StartupListener.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -73,7 +73,10 @@
List algorithmTypes = new ArrayList();
algorithmTypes.add(Constants.ALGORITHM_LIKELIHOOD);
algorithmTypes.add(Constants.ALGORITHM_PARSIMONY);
- algorithmTypes.add(Constants.ALGORITHM_DISTANCE);
+ algorithmTypes.add(Constants.ALGORITHM_Bayesian);
+ algorithmTypes.add(Constants.ALGORITHM_Evolution);
+ algorithmTypes.add(Constants.ALGORITHM_Joining);
+ algorithmTypes.add(Constants.ALGORITHM_UPGMA);
algorithmTypes.add(Constants.ALGORITHM_OTHER);
context.setAttribute(Constants.ALGORITHM_TYPES, algorithmTypes);
Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/AnalysisStepCommand.java
===================================================================
--- trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/AnalysisStepCommand.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/AnalysisStepCommand.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -12,11 +12,14 @@
import org.cipres.treebase.domain.matrix.PolyTCount;
import org.cipres.treebase.domain.study.Algorithm;
import org.cipres.treebase.domain.study.AnalysisStep;
-import org.cipres.treebase.domain.study.DistanceAlgorithm;
+import org.cipres.treebase.domain.study.BayesianAlgorithm;
+import org.cipres.treebase.domain.study.EvolutionAlgorithm;
+import org.cipres.treebase.domain.study.JoiningAlgorithm;
import org.cipres.treebase.domain.study.LikelihoodAlgorithm;
import org.cipres.treebase.domain.study.OtherAlgorithm;
import org.cipres.treebase.domain.study.ParsimonyAlgorithm;
import org.cipres.treebase.domain.study.Software;
+import org.cipres.treebase.domain.study.UPGMAAlgorithm;
import org.cipres.treebase.web.Constants;
/**
@@ -47,7 +50,10 @@
private List<String> mUniqueAlgorithmDescriptions;
public AnalysisStepCommand() {
- algorithmMap.put(Constants.ALGORITHM_DISTANCE, new DistanceAlgorithm());
+ algorithmMap.put(Constants.ALGORITHM_Bayesian, new BayesianAlgorithm());
+ algorithmMap.put(Constants.ALGORITHM_Evolution, new EvolutionAlgorithm());
+ algorithmMap.put(Constants.ALGORITHM_Joining, new JoiningAlgorithm());
+ algorithmMap.put(Constants.ALGORITHM_UPGMA, new UPGMAAlgorithm());
algorithmMap.put(Constants.ALGORITHM_LIKELIHOOD, new LikelihoodAlgorithm());
algorithmMap.put(Constants.ALGORITHM_OTHER, new OtherAlgorithm());
// ParsimonyAlgorithm parsimonyAlgorithm = new ParsimonyAlgorithm();
Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/ControllerUtil.java
===================================================================
--- trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/ControllerUtil.java 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/ControllerUtil.java 2010-02-24 14:53:46 UTC (rev 517)
@@ -17,12 +17,15 @@
import org.cipres.treebase.domain.study.Algorithm;
import org.cipres.treebase.domain.study.Analysis;
import org.cipres.treebase.domain.study.AnalysisStep;
-import org.cipres.treebase.domain.study.DistanceAlgorithm;
+import org.cipres.treebase.domain.study.BayesianAlgorithm;
+import org.cipres.treebase.domain.study.EvolutionAlgorithm;
+import org.cipres.treebase.domain.study.JoiningAlgorithm;
import org.cipres.treebase.domain.study.LikelihoodAlgorithm;
import org.cipres.treebase.domain.study.OtherAlgorithm;
import org.cipres.treebase.domain.study.ParsimonyAlgorithm;
import org.cipres.treebase.domain.study.Study;
import org.cipres.treebase.domain.study.StudyService;
+import org.cipres.treebase.domain.study.UPGMAAlgorithm;
import org.cipres.treebase.web.Constants;
import org.cipres.treebase.web.exceptions.EmptyStudyException;
@@ -246,8 +249,14 @@
type = Constants.ALGORITHM_LIKELIHOOD;
} else if (algorithm instanceof ParsimonyAlgorithm) {
type = Constants.ALGORITHM_PARSIMONY;
- } else if (algorithm instanceof DistanceAlgorithm) {
- type = Constants.ALGORITHM_DISTANCE;
+ } else if (algorithm instanceof BayesianAlgorithm) {
+ type = Constants.ALGORITHM_Bayesian;
+ } else if (algorithm instanceof EvolutionAlgorithm) {
+ type = Constants.ALGORITHM_Evolution;
+ } else if (algorithm instanceof JoiningAlgorithm) {
+ type = Constants.ALGORITHM_Joining;
+ } else if (algorithm instanceof UPGMAAlgorithm) {
+ type = Constants.ALGORITHM_UPGMA;
} else if (algorithm instanceof OtherAlgorithm) {
type = Constants.ALGORITHM_OTHER;
}
Modified: trunk/treebase-web/src/main/webapp/WEB-INF/pages/submissionSummaryView.jsp
===================================================================
--- trunk/treebase-web/src/main/webapp/WEB-INF/pages/submissionSummaryView.jsp 2010-02-19 21:50:27 UTC (rev 516)
+++ trunk/treebase-web/src/main/webapp/WEB-INF/pages/submissionSummaryView.jsp 2010-02-24 14:53:46 UTC (rev 517)
@@ -11,16 +11,31 @@
</legend>
Submission: <c:out value="${submissionNumber}"/>, <c:out value="${studyStatus}"/>, <a href="/treebase-web/admin/changeStudyStatus.html"> Update Status</a><br/>
Submission initiated: <c:out value="${initiatedDate}"/><br/>
-<a href='mailto:${submission.submitter.emailAddressString}?subject=TreeBASE Submission S${submission.id}'>
- <img class="iconButton" alt="mail" src="<fmt:message key="icons.email"/>" />
- Contact Submitter
-</a>
-<br/>
-<a href="<c:out value="${submission.study.phyloWSPath.purl}"/>?x-access-code=<c:out value="${submission.study.namespacedGUID.hashedIDString}"/>&format=html">
- <img class="iconButton" alt="link" src="<fmt:message key="icons.weblink"/>" />
- Reviewer access URL: right-click and copy
-</a>
+<%if(request.isUserInRole("Admin") || request.isUserInRole("Associate Editor")){%>
+ <a href='mailto:${submission.submitter.emailAddressString}?subject=TreeBASE Submission S${submission.id}'>
+ <img class="iconButton" alt="mail" src="<fmt:message key="icons.email"/>" />
+ Contact Submitter
+ </a>
+ <br/>
+ <a href="<c:out value="${submission.study.phyloWSPath.purl}"/>?x-access-code=<c:out value="${submission.study.namespacedGUID.hashedIDString}"/>&format=html">
+ <img class="iconButton" alt="link" src="<fmt:message key="icons.weblink"/>" />
+ Reviewer access URL: right-click and copy
+ </a>
+<% } %>
+
+<%if(request.isUserInRole("User") ){%>
+ <a href='mailto:he...@tr...?subject=TreeBASE Submission S${submission.id}'>
+ <img class="iconButton" alt="mail" src="<fmt:message key="icons.email"/>" />
+ Contact TreeBASE Help
+ </a>
+ <br/>
+ <a href="<c:out value="http://purl.org/phylo/treebase/phylows/study/TB2:S"/><c:out value="${submission.study.id}"/>">
+ <img class="iconButton" alt="link" src="<fmt:message key="icons.weblink"/>" />
+ Study Accession URL: right-click and copy
+ </a>
+<% } %>
+
<c:if test="${not empty citationsummary.study}">
<c:if test="${not empty citationsummary.study.name}">
Study name: <c:out value="${citationsummary.study.name}"/>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|