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 extends ForwardingObject implements Collection { /* JADX INFO: Access modifiers changed from: protected */ @Override // com.google.common.collect.ForwardingObject public abstract Collection delegate(); public Iterator 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 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[] 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 collection) { return Iterators.addAll(this, collection.iterator()); } protected boolean standardRemove(Object obj) { Iterator 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[] standardToArray(T[] tArr) { return (T[]) ObjectArrays.toArrayImpl(this, tArr); } }