124 lines
3.4 KiB
Java
124 lines
3.4 KiB
Java
package com.google.common.collect;
|
|
|
|
import com.google.common.base.Objects;
|
|
import java.util.Collection;
|
|
import java.util.Iterator;
|
|
|
|
/* loaded from: classes2.dex */
|
|
public abstract class ForwardingCollection<E> extends ForwardingObject implements Collection<E> {
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
@Override // com.google.common.collect.ForwardingObject
|
|
public abstract Collection<E> delegate();
|
|
|
|
public Iterator<E> iterator() {
|
|
return delegate().iterator();
|
|
}
|
|
|
|
@Override // java.util.Collection
|
|
public int size() {
|
|
return delegate().size();
|
|
}
|
|
|
|
public boolean removeAll(Collection<?> collection) {
|
|
return delegate().removeAll(collection);
|
|
}
|
|
|
|
@Override // java.util.Collection
|
|
public boolean isEmpty() {
|
|
return delegate().isEmpty();
|
|
}
|
|
|
|
public boolean contains(Object obj) {
|
|
return delegate().contains(obj);
|
|
}
|
|
|
|
public boolean add(E e) {
|
|
return delegate().add(e);
|
|
}
|
|
|
|
public boolean remove(Object obj) {
|
|
return delegate().remove(obj);
|
|
}
|
|
|
|
public boolean containsAll(Collection<?> collection) {
|
|
return delegate().containsAll(collection);
|
|
}
|
|
|
|
public boolean addAll(Collection<? extends E> collection) {
|
|
return delegate().addAll(collection);
|
|
}
|
|
|
|
public boolean retainAll(Collection<?> collection) {
|
|
return delegate().retainAll(collection);
|
|
}
|
|
|
|
public void clear() {
|
|
delegate().clear();
|
|
}
|
|
|
|
public Object[] toArray() {
|
|
return delegate().toArray();
|
|
}
|
|
|
|
public <T> T[] toArray(T[] tArr) {
|
|
return (T[]) delegate().toArray(tArr);
|
|
}
|
|
|
|
protected boolean standardContains(Object obj) {
|
|
return Iterators.contains(iterator(), obj);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
public boolean standardContainsAll(Collection<?> collection) {
|
|
return Collections2.containsAllImpl(this, collection);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
public boolean standardAddAll(Collection<? extends E> collection) {
|
|
return Iterators.addAll(this, collection.iterator());
|
|
}
|
|
|
|
protected boolean standardRemove(Object obj) {
|
|
Iterator<E> it = iterator();
|
|
while (it.hasNext()) {
|
|
if (Objects.equal(it.next(), obj)) {
|
|
it.remove();
|
|
return true;
|
|
}
|
|
}
|
|
return false;
|
|
}
|
|
|
|
protected boolean standardRemoveAll(Collection<?> collection) {
|
|
return Iterators.removeAll(iterator(), collection);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
public boolean standardRetainAll(Collection<?> collection) {
|
|
return Iterators.retainAll(iterator(), collection);
|
|
}
|
|
|
|
protected void standardClear() {
|
|
Iterators.clear(iterator());
|
|
}
|
|
|
|
protected boolean standardIsEmpty() {
|
|
return !iterator().hasNext();
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
public String standardToString() {
|
|
return Collections2.toStringImpl(this);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
public Object[] standardToArray() {
|
|
return toArray(new Object[size()]);
|
|
}
|
|
|
|
/* JADX INFO: Access modifiers changed from: protected */
|
|
public <T> T[] standardToArray(T[] tArr) {
|
|
return (T[]) ObjectArrays.toArrayImpl(this, tArr);
|
|
}
|
|
}
|