本文整理匯總了Java中com.google.common.collect.Iterators.elementsEqual方法的典型用法代碼示例。如果您正苦於以下問題:Java Iterators.elementsEqual方法的具體用法?Java Iterators.elementsEqual怎麽用?Java Iterators.elementsEqual使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.google.common.collect.Iterators
的用法示例。
在下文中一共展示了Iterators.elementsEqual方法的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: equals
import com.google.common.collect.Iterators; //導入方法依賴的package包/類
@Override
public boolean equals(Object o)
{
if(!(o instanceof IntervalTree))
return false;
IntervalTree that = (IntervalTree)o;
return Iterators.elementsEqual(iterator(), that.iterator());
}
示例2: equals
import com.google.common.collect.Iterators; //導入方法依賴的package包/類
@Override
public synchronized boolean equals(Object genericRight) {
if (genericRight instanceof CounterGroupBase<?>) {
@SuppressWarnings("unchecked")
CounterGroupBase<Counter> right = ((CounterGroupBase<Counter>)
genericRight).getUnderlyingGroup();
return Iterators.elementsEqual(iterator(), right.iterator());
}
return false;
}
示例3: equals
import com.google.common.collect.Iterators; //導入方法依賴的package包/類
@Override
public synchronized boolean equals(Object genericRight) {
if (genericRight instanceof CounterGroupBase<?>) {
@SuppressWarnings("unchecked")
CounterGroupBase<T> right = (CounterGroupBase<T>) genericRight;
return Iterators.elementsEqual(iterator(), right.iterator());
}
return false;
}
示例4: equals
import com.google.common.collect.Iterators; //導入方法依賴的package包/類
@Override
public boolean equals(Object genericRight) {
if (genericRight instanceof CounterGroupBase<?>) {
@SuppressWarnings("unchecked")
CounterGroupBase<C> right = (CounterGroupBase<C>) genericRight;
return Iterators.elementsEqual(iterator(), right.iterator());
}
return false;
}
示例5: equals
import com.google.common.collect.Iterators; //導入方法依賴的package包/類
@Override
@SuppressWarnings("unchecked")
public boolean equals(Object genericRight) {
if (genericRight instanceof AbstractCounters<?, ?>) {
return Iterators.elementsEqual(iterator(),
((AbstractCounters<C, G>)genericRight).iterator());
}
return false;
}
示例6: equals
import com.google.common.collect.Iterators; //導入方法依賴的package包/類
@Override
public synchronized boolean equals(Object genericRight) {
if (genericRight instanceof CounterGroupBase<?>) {
@SuppressWarnings("unchecked")
CounterGroupBase<C> right = (CounterGroupBase<C>) genericRight;
return Iterators.elementsEqual(iterator(), right.iterator());
}
return false;
}
示例7: equals
import com.google.common.collect.Iterators; //導入方法依賴的package包/類
public static boolean equals(Object[] a, Object[] b)
{
return size(a) == size(b) && Iterators.elementsEqual(iterator(a), iterator(b));
}