Example usage for org.apache.commons.collections15 SetUtils isEqualSet

List of usage examples for org.apache.commons.collections15 SetUtils isEqualSet

Introduction

In this page you can find the example usage for org.apache.commons.collections15 SetUtils isEqualSet.

Prototype

public static boolean isEqualSet(final Collection set1, final Collection set2) 

Source Link

Document

Tests two sets for equality as per the equals() contract in java.util.Set#equals(java.lang.Object) .

Usage

From source file:de.dhke.projects.cutil.collections.frozen.FrozenSortedList.java

@Override
public boolean equals(Object o) {
    if (o instanceof Collection) {
        Collection<?> c = (Collection<?>) o;
        return SetUtils.isEqualSet(_elements, c);
    } else//www .  ja  va  2 s . c o m
        return false;
}

From source file:logicProteinHypernetwork.analysis.complexes.Complex.java

@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }//from ww w . ja  v  a 2s  .  com
    if (getClass() != obj.getClass()) {
        return false;
    }
    final Complex other = (Complex) obj;

    return SetUtils.isEqualSet(this, other);
}

From source file:de.dhke.projects.cutil.collections.frozen.FrozenFlat3Set.java

@Override
public boolean equals(Object obj) {
    if (this == obj)
        return true;
    else if (obj instanceof Collection)
        return SetUtils.isEqualSet(this, (Collection<?>) obj);
    else//w ww  . j a v a2s .c  o m
        return false;
}

From source file:logicProteinHypernetwork.networkStates.MinimalNetworkState.java

@Override
public boolean equals(Object obj) {
    if (obj == null) {
        return false;
    }//from www . jav  a  2s .  c om
    if (getClass() != obj.getClass()) {
        return false;
    }
    final MinimalNetworkState other = (MinimalNetworkState) obj;

    return SetUtils.isEqualSet(necessary, other.necessary) && SetUtils.isEqualSet(impossible, other.impossible);
}

From source file:de.dhke.projects.cutil.collections.frozen.FrozenSet.java

@Override
public boolean equals(Object obj) {
    if (this == obj)
        return true;
    else if (obj instanceof Collection)
        return SetUtils.isEqualSet(_baseSet, (Collection<?>) obj);
    else//w  ww . j  ava 2  s .c  o  m
        return false;
}

From source file:de.uniba.wiai.kinf.pw.projects.lillytab.reasoner.abox.ABoxNode.java

@Override
public boolean deepEquals(final Object obj) {
    if (obj instanceof ABoxNode) {
        @SuppressWarnings("unchecked")
        final ABoxNode<?, I, L, K, R> other = (ABoxNode<?, I, L, K, R>) obj;
        if (!SetUtils.isEqualSet(getTerms(), other.getTerms())) {
            return false;
        }//from   www  .  jav  a  2s  .  co m
        if (!_raBox.deepEquals(other.getRABox())) {
            return false;
        }
        return true;
    } else {
        return false;
    }
}