package uk.ac.ebi.gxa.statistics;

import java.util.Collection;
import java.util.HashSet;
import java.util.Set;

/**
 * Created by IntelliJ IDEA.
 * User: rpetry
 * Date: Dec 3, 2010
 * Time: 3:27:59 PM
 * This class represents an OR collection of conditions of type: ConditionType.
 */
public class StatisticsQueryOrConditions<ConditionType> {
    private Set<ConditionType> orConditions = new HashSet<ConditionType>();
    // If orConditions represents an OR collection of experiment-efv combinations
    // corresponding to an efo term, efoTerm is used to hold that term's name.
    String efoTerm = null;
    // Set of gene ids of interest to which this query is restricted
    private Set<Long> geneRestrictionSet = null;

    /**
     * Constructor
     */
    public StatisticsQueryOrConditions() {
    }

    public String getEfoTerm() {
        return efoTerm;
    }

    public void setEfoTerm(String efoTerm) {
        this.efoTerm = efoTerm;
    }

    public void orCondition(ConditionType condition) {
        this.orConditions.add(condition);
    }

    public Set<ConditionType> getConditions() {
        return orConditions;
    }

    public Set<Long> getGeneRestrictionSet() {
        return geneRestrictionSet;
    }

    public void setGeneRestrictionSet(Set<Long> geneRestrictionSet) {
        this.geneRestrictionSet = geneRestrictionSet;
    }

    @Override
    public String toString() {
        return orConditions.toString();
    }

}


@@ -418,195 +418,8 @@
 ();%0A
-    // If orConditions represents an OR collection of experiment-efv combinations%0A    // corresponding to an efo term, efoTerm is used to hold that term's name.%0A    String efoTerm = null;
 %0A   
@@ -623,156 +623,8 @@
  %7D%0A%0A
-    public String getEfoTerm() %7B%0A        return efoTerm;%0A    %7D%0A%0A    public void setEfoTerm(String efoTerm) %7B%0A        this.efoTerm = efoTerm;%0A    %7D%0A%0A
     

Remove efoTerm, as we now group multiple efos' mappings into a single StatisticsQueryOrConditions