import "copyrightAndOthers.stg"
import "primitiveEquals.stg"
import "primitiveHashCode.stg"
import "primitiveLiteral.stg"

targetPath() ::= "org/eclipse/collections/impl/map/mutable/primitive"

fileName(primitive) ::= "Synchronized<primitive.name>ObjectMap"

skipBoolean() ::= "true"

class(primitive) ::= <<
<body(primitive.type, primitive.name)>
>>

collectPrimitive(name, type) ::= <<
@Override
public Mutable<name>Bag collect<name>(<name>Function\<? super V> <type>Function)
{
    synchronized (this.lock)
    {
        return this.map.collect<name>(<type>Function);
    }
}

@Override
public \<R extends Mutable<name>Collection> R collect<name>(<name>Function\<? super V> <type>Function, R target)
{
    synchronized (this.lock)
    {
        return this.map.collect<name>(<type>Function, target);
    }
}
>>

body(type, name) ::= <<
<copyrightAndOthers()>

package org.eclipse.collections.impl.map.mutable.primitive;

import java.io.Serializable;
import java.util.Collection;
import java.util.Collections;
import java.util.Comparator;
import java.util.Iterator;
import java.util.Map;
import java.util.Optional;

import org.eclipse.collections.api.BooleanIterable;
import org.eclipse.collections.api.ByteIterable;
import org.eclipse.collections.api.CharIterable;
import org.eclipse.collections.api.DoubleIterable;
import org.eclipse.collections.api.FloatIterable;
import org.eclipse.collections.api.IntIterable;
import org.eclipse.collections.api.LongIterable;
import org.eclipse.collections.api.ShortIterable;
import org.eclipse.collections.api.Lazy<name>Iterable;
import org.eclipse.collections.api.LazyIterable;
import org.eclipse.collections.api.RichIterable;
import org.eclipse.collections.api.bag.ImmutableBag;
import org.eclipse.collections.api.bag.MutableBag;
import org.eclipse.collections.api.bag.primitive.MutableBooleanBag;
import org.eclipse.collections.api.bag.primitive.MutableByteBag;
import org.eclipse.collections.api.bag.primitive.MutableCharBag;
import org.eclipse.collections.api.bag.primitive.MutableDoubleBag;
import org.eclipse.collections.api.bag.primitive.MutableFloatBag;
import org.eclipse.collections.api.bag.primitive.MutableIntBag;
import org.eclipse.collections.api.bag.primitive.MutableLongBag;
import org.eclipse.collections.api.bag.primitive.MutableShortBag;
import org.eclipse.collections.api.bag.sorted.ImmutableSortedBag;
import org.eclipse.collections.api.bag.sorted.MutableSortedBag;
import org.eclipse.collections.api.bimap.MutableBiMap;
import org.eclipse.collections.api.block.function.Function;
import org.eclipse.collections.api.block.function.Function0;
import org.eclipse.collections.api.block.function.Function2;
import org.eclipse.collections.api.block.function.primitive.<name>ToObjectFunction;
import org.eclipse.collections.api.block.function.primitive.BooleanFunction;
import org.eclipse.collections.api.block.function.primitive.ByteFunction;
import org.eclipse.collections.api.block.function.primitive.CharFunction;
import org.eclipse.collections.api.block.function.primitive.DoubleFunction;
import org.eclipse.collections.api.block.function.primitive.DoubleObjectToDoubleFunction;
import org.eclipse.collections.api.block.function.primitive.FloatFunction;
import org.eclipse.collections.api.block.function.primitive.FloatObjectToFloatFunction;
import org.eclipse.collections.api.block.function.primitive.IntFunction;
import org.eclipse.collections.api.block.function.primitive.IntObjectToIntFunction;
import org.eclipse.collections.api.block.function.primitive.LongFunction;
import org.eclipse.collections.api.block.function.primitive.LongObjectToLongFunction;
import org.eclipse.collections.api.block.function.primitive.ShortFunction;
import org.eclipse.collections.api.block.predicate.Predicate;
import org.eclipse.collections.api.block.predicate.Predicate2;
import org.eclipse.collections.api.block.predicate.primitive.<name>ObjectPredicate;
import org.eclipse.collections.api.block.procedure.Procedure;
import org.eclipse.collections.api.block.procedure.Procedure2;
import org.eclipse.collections.api.block.procedure.primitive.<name>ObjectProcedure;
import org.eclipse.collections.api.block.procedure.primitive.<name>Procedure;
import org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure;
import org.eclipse.collections.api.collection.primitive.MutableBooleanCollection;
import org.eclipse.collections.api.collection.primitive.MutableByteCollection;
import org.eclipse.collections.api.collection.primitive.MutableCharCollection;
import org.eclipse.collections.api.collection.primitive.MutableDoubleCollection;
import org.eclipse.collections.api.collection.primitive.MutableFloatCollection;
import org.eclipse.collections.api.collection.primitive.MutableIntCollection;
import org.eclipse.collections.api.collection.primitive.MutableLongCollection;
import org.eclipse.collections.api.collection.primitive.MutableShortCollection;
import org.eclipse.collections.api.list.ImmutableList;
import org.eclipse.collections.api.list.MutableList;
import org.eclipse.collections.api.map.MutableMap;
import org.eclipse.collections.api.map.MutableMapIterable;
import org.eclipse.collections.api.map.primitive.<name>ObjectMap;
import org.eclipse.collections.api.map.primitive.Mutable<name>ObjectMap;
<if(!primitive.longPrimitive)><if(!primitive.doublePrimitive)>import org.eclipse.collections.api.map.primitive.MutableObject<name>Map;<endif><endif>
import org.eclipse.collections.api.map.primitive.Immutable<name>ObjectMap;
import org.eclipse.collections.api.map.primitive.MutableObjectDoubleMap;
import org.eclipse.collections.api.map.primitive.MutableObjectLongMap;
import org.eclipse.collections.api.map.sorted.MutableSortedMap;
import org.eclipse.collections.api.multimap.MutableMultimap;
import org.eclipse.collections.api.multimap.bag.MutableBagMultimap;
import org.eclipse.collections.api.ordered.OrderedIterable;
import org.eclipse.collections.api.partition.bag.PartitionMutableBag;
import org.eclipse.collections.api.set.ImmutableSet;
import org.eclipse.collections.api.set.MutableSet;
import org.eclipse.collections.api.set.primitive.Mutable<name>Set;
import org.eclipse.collections.api.set.sorted.ImmutableSortedSet;
import org.eclipse.collections.api.set.sorted.MutableSortedSet;
import org.eclipse.collections.api.tuple.Pair;
import org.eclipse.collections.api.tuple.primitive.<name>ObjectPair;
import org.eclipse.collections.impl.SynchronizedRichIterable;
import org.eclipse.collections.impl.collection.mutable.CollectionAdapter;
import org.eclipse.collections.impl.collection.mutable.SynchronizedMutableCollection;
import org.eclipse.collections.impl.factory.primitive.<name>ObjectMaps;
import org.eclipse.collections.impl.primitive.Synchronized<name>Iterable;
import org.eclipse.collections.impl.set.mutable.primitive.Synchronized<name>Set;

/**
 * A synchronized view of a {@link Mutable<name>ObjectMap}. It is imperative that the user manually synchronize on the collection when iterating over it using the
 * standard JDK iterator or JDK 5 for loop, as per {@link Collections#synchronizedCollection(Collection)}.
 * \<p>
 * This file was automatically generated from template file synchronizedPrimitiveObjectMap.stg.
 *
 * @see Mutable<name>ObjectMap#asSynchronized()
 * @see MutableMap#asSynchronized()
 * @since 3.1.
 */
public class Synchronized<name>ObjectMap\<V>
        implements Mutable<name>ObjectMap\<V>, Serializable
{
    private static final long serialVersionUID = 1L;
    private final Object lock;
    private final Mutable<name>ObjectMap\<V> map;

    public Synchronized<name>ObjectMap(Mutable<name>ObjectMap\<V> map)
    {
        this(map, null);
    }

    public Synchronized<name>ObjectMap(Mutable<name>ObjectMap\<V> map, Object newLock)
    {
        if (map == null)
        {
            throw new IllegalArgumentException("Cannot create a Synchronized<name>ObjectMap on a null map");
        }

        this.map = map;
        this.lock = newLock == null ? this : newLock;
    }

    @Override
    public V put(<type> key, V value)
    {
        synchronized (this.lock)
        {
            return this.map.put(key, value);
        }
    }

    @Override
    public V putPair(<name>ObjectPair\<V> keyValuePair)
    {
        synchronized (this.lock)
        {
            return this.map.put(keyValuePair.getOne(), keyValuePair.getTwo());
        }
    }

    @Override
    public void putAll(<name>ObjectMap\<? extends V> map)
    {
        synchronized (this.lock)
        {
            map.forEachKeyValue(this.map::put);
        }
    }

    @Override
    public V removeKey(<type> key)
    {
        synchronized (this.lock)
        {
            return this.map.removeKey(key);
        }
    }

    @Override
    public V remove(<type> key)
    {
        synchronized (this.lock)
        {
            return this.map.remove(key);
        }
    }

    @Override
    public V getIfAbsentPut(<type> key, V value)
    {
        synchronized (this.lock)
        {
            return this.map.getIfAbsentPut(key, value);
        }
    }

    @Override
    public V getIfAbsentPut(<type> key, Function0\<? extends V> function)
    {
        synchronized (this.lock)
        {
            return this.map.getIfAbsentPut(key, function);
        }
    }

    @Override
    public V getIfAbsentPutWithKey(<type> key, <name>ToObjectFunction\<? extends V> function)
    {
        synchronized (this.lock)
        {
            return this.map.getIfAbsentPutWithKey(key, function);
        }
    }

    @Override
    public \<P> V getIfAbsentPutWith(<type> key, Function\<? super P, ? extends V> function, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.getIfAbsentPutWith(key, function, parameter);
        }
    }

    @Override
    public V updateValue(<type> key, Function0\<? extends V> factory, Function\<? super V, ? extends V> function)
    {
        synchronized (this.lock)
        {
            return this.map.updateValue(key, factory, function);
        }
    }

    @Override
    public \<P> V updateValueWith(<type> key, Function0\<? extends V> factory, Function2\<? super V, ? super P, ? extends V> function, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.updateValueWith(key, factory, function, parameter);
        }
    }

    @Override
    public V get(<type> key)
    {
        synchronized (this.lock)
        {
            return this.map.get(key);
        }
    }

    @Override
    public V getIfAbsent(<type> key, Function0\<? extends V> ifAbsent)
    {
        synchronized (this.lock)
        {
            return this.map.getIfAbsent(key, ifAbsent);
        }
    }

    @Override
    public boolean containsKey(<type> key)
    {
        synchronized (this.lock)
        {
            return this.map.containsKey(key);
        }
    }

    @Override
    public boolean containsValue(Object value)
    {
        synchronized (this.lock)
        {
            return this.map.containsValue(value);
        }
    }

    @Override
    public Mutable<name>ObjectMap\<V> tap(Procedure\<? super V> procedure)
    {
        synchronized (this.lock)
        {
            this.map.forEach(procedure);
            return this;
        }
    }

    @Override
    public void forEachValue(Procedure\<? super V> procedure)
    {
        synchronized (this.lock)
        {
            this.map.forEachValue(procedure);
        }
    }

    @Override
    public void forEachKey(<name>Procedure procedure)
    {
        synchronized (this.lock)
        {
            this.map.forEachKey(procedure);
        }
    }

    @Override
    public void forEachKeyValue(<name>ObjectProcedure\<? super V> procedure)
    {
        synchronized (this.lock)
        {
            this.map.forEachKeyValue(procedure);
        }
    }

    @Override
    public Mutable<name>ObjectMap\<V> select(<name>ObjectPredicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.select(predicate);
        }
    }

    @Override
    public Mutable<name>ObjectMap\<V> reject(<name>ObjectPredicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.reject(predicate);
        }
    }

    @Override
    public int size()
    {
        synchronized (this.lock)
        {
            return this.map.size();
        }
    }

    @Override
    public boolean isEmpty()
    {
        synchronized (this.lock)
        {
            return this.map.isEmpty();
        }
    }

    @Override
    public boolean notEmpty()
    {
        synchronized (this.lock)
        {
            return this.map.notEmpty();
        }
    }

    @Override
    public V getFirst()
    {
        synchronized (this.lock)
        {
            return this.map.getFirst();
        }
    }

    @Override
    public V getLast()
    {
        synchronized (this.lock)
        {
            return this.map.getLast();
        }
    }

    @Override
    public V getOnly()
    {
        synchronized (this.lock)
        {
            return this.map.getOnly();
        }
    }

    @Override
    public boolean contains(Object object)
    {
        synchronized (this.lock)
        {
            return this.map.contains(object);
        }
    }

    @Override
    public boolean containsAllIterable(Iterable\<?> source)
    {
        synchronized (this.lock)
        {
            return this.map.containsAllIterable(source);
        }
    }

    @Override
    public boolean containsAll(Collection\<?> source)
    {
        synchronized (this.lock)
        {
            return this.map.containsAll(source);
        }
    }

    @Override
    public boolean containsNoneIterable(Iterable\<?> source)
    {
        synchronized (this.lock)
        {
            return this.map.containsNoneIterable(source);
        }
    }

    @Override
    public boolean containsNone(Collection\<?> source)
    {
        synchronized (this.lock)
        {
            return this.map.containsNone(source);
        }
    }

    @Override
    public boolean containsAnyIterable(Iterable\<?> source)
    {
        synchronized (this.lock)
        {
            return this.map.containsAnyIterable(source);
        }
    }

    @Override
    public boolean containsAny(Collection\<?> source)
    {
        synchronized (this.lock)
        {
            return this.map.containsAny(source);
        }
    }

    @Override
    public boolean containsAllArguments(Object... elements)
    {
        synchronized (this.lock)
        {
            return this.map.containsAllArguments(elements);
        }
    }

    @Override
    public MutableBag\<V> select(Predicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.select(predicate);
        }
    }

    @Override
    public \<R extends Collection\<V>\> R select(Predicate\<? super V> predicate, R target)
    {
        synchronized (this.lock)
        {
            return this.map.select(predicate, target);
        }
    }

    @Override
    public \<P> MutableBag\<V> selectWith(Predicate2\<? super V, ? super P> predicate, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.selectWith(predicate, parameter);
        }
    }

    @Override
    public \<P, R extends Collection\<V>\> R selectWith(Predicate2\<? super V, ? super P> predicate, P parameter, R targetCollection)
    {
        synchronized (this.lock)
        {
            return this.map.selectWith(predicate, parameter, targetCollection);
        }
    }

    @Override
    public PartitionMutableBag\<V> partition(Predicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.partition(predicate);
        }
    }

    @Override
    public \<P> PartitionMutableBag\<V> partitionWith(Predicate2\<? super V, ? super P> predicate, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.partitionWith(predicate, parameter);
        }
    }

    @Override
    public \<S> MutableBag\<S> selectInstancesOf(Class\<S> clazz)
    {
        synchronized (this.lock)
        {
            return this.map.selectInstancesOf(clazz);
        }
    }

    /**
     * @deprecated in 7.0. Use {@link OrderedIterable#zipWithIndex()} instead.
     */
    @Deprecated
    @Override
    public MutableSet\<Pair\<V, Integer>\> zipWithIndex()
    {
        synchronized (this.lock)
        {
            return this.map.zipWithIndex();
        }
    }

    @Override
    public \<R extends Collection\<Pair\<V, Integer>\>> R zipWithIndex(R target)
    {
        synchronized (this.lock)
        {
            return this.map.zipWithIndex(target);
        }
    }

    @Override
    public RichIterable\<RichIterable\<V>\> chunk(int size)
    {
        synchronized (this.lock)
        {
            return this.map.chunk(size);
        }
    }

    @Override
    public \<K, VV> MutableMap\<K, VV> aggregateInPlaceBy(Function\<? super V, ? extends K> groupBy, Function0\<? extends VV> zeroValueFactory, Procedure2\<? super VV, ? super V> mutatingAggregator)
    {
        synchronized (this.lock)
        {
            return this.map.aggregateInPlaceBy(groupBy, zeroValueFactory, mutatingAggregator);
        }
    }

    @Override
    public \<K, VV> MutableMap\<K, VV> aggregateBy(Function\<? super V, ? extends K> groupBy, Function0\<? extends VV> zeroValueFactory, Function2\<? super VV, ? super V, ? extends VV> nonMutatingAggregator)
    {
        synchronized (this.lock)
        {
            return this.map.aggregateBy(groupBy, zeroValueFactory, nonMutatingAggregator);
        }
    }

    @Override
    public MutableBag\<V> reject(Predicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.reject(predicate);
        }
    }

    @Override
    public \<R extends Collection\<V>\> R reject(Predicate\<? super V> predicate, R target)
    {
        synchronized (this.lock)
        {
            return this.map.reject(predicate, target);
        }
    }

    @Override
    public \<P> MutableBag\<V> rejectWith(Predicate2\<? super V, ? super P> predicate, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.rejectWith(predicate, parameter);
        }
    }

    @Override
    public \<P, R extends Collection\<V>\> R rejectWith(Predicate2\<? super V, ? super P> predicate, P parameter, R targetCollection)
    {
        synchronized (this.lock)
        {
            return this.map.rejectWith(predicate, parameter, targetCollection);
        }
    }

    @Override
    public void clear()
    {
        synchronized (this.lock)
        {
            this.map.clear();
        }
    }

    @Override
    public \<VV> MutableBag\<VV> collect(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.collect(function);
        }
    }

    <collectPrimitive("Boolean", "boolean")>

    <collectPrimitive("Byte", "byte")>

    <collectPrimitive("Char", "char")>

    <collectPrimitive("Double", "double")>

    <collectPrimitive("Float", "float")>

    <collectPrimitive("Int", "int")>

    <collectPrimitive("Long", "long")>

    <collectPrimitive("Short", "short")>

    @Override
    public \<P, VV> MutableBag\<VV> collectWith(Function2\<? super V, ? super P, ? extends VV> function, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.collectWith(function, parameter);
        }
    }

    @Override
    public \<P, VV, R extends Collection\<VV>\> R collectWith(Function2\<? super V, ? super P, ? extends VV> function, P parameter, R targetCollection)
    {
        synchronized (this.lock)
        {
            return this.map.collectWith(function, parameter, targetCollection);
        }
    }

    @Override
    public \<VV, R extends Collection\<VV>\> R collect(Function\<? super V, ? extends VV> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.collect(function, target);
        }
    }

    @Override
    public \<VV> MutableBag\<VV> collectIf(Predicate\<? super V> predicate, Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.collectIf(predicate, function);
        }
    }

    @Override
    public \<VV, R extends Collection\<VV>\> R collectIf(Predicate\<? super V> predicate, Function\<? super V, ? extends VV> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.collectIf(predicate, function, target);
        }
    }

    @Override
    public \<VV> MutableBag\<VV> flatCollect(Function\<? super V, ? extends Iterable\<VV>\> function)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollect(function);
        }
    }

    @Override
    public \<VV, R extends Collection\<VV>\> R flatCollect(Function\<? super V, ? extends Iterable\<VV>\> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollect(function, target);
        }
    }

    @Override
    public \<R extends MutableByteCollection> R flatCollectByte(
            Function\<? super V, ? extends ByteIterable> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollectByte(function, target);
        }
    }

    @Override
    public \<R extends MutableCharCollection> R flatCollectChar(
            Function\<? super V, ? extends CharIterable> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollectChar(function, target);
        }
    }

    @Override
    public \<R extends MutableIntCollection> R flatCollectInt(
            Function\<? super V, ? extends IntIterable> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollectInt(function, target);
        }
    }

    @Override
    public \<R extends MutableShortCollection> R flatCollectShort(
            Function\<? super V, ? extends ShortIterable> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollectShort(function, target);
        }
    }

    @Override
    public \<R extends MutableDoubleCollection> R flatCollectDouble(
            Function\<? super V, ? extends DoubleIterable> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollectDouble(function, target);
        }
    }

    @Override
    public \<R extends MutableFloatCollection> R flatCollectFloat(
            Function\<? super V, ? extends FloatIterable> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollectFloat(function, target);
        }
    }

    @Override
    public \<R extends MutableLongCollection> R flatCollectLong(
            Function\<? super V, ? extends LongIterable> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollectLong(function, target);
        }
    }

    @Override
    public \<R extends MutableBooleanCollection> R flatCollectBoolean(
            Function\<? super V, ? extends BooleanIterable> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.flatCollectBoolean(function, target);
        }
    }

    @Override
    public V detect(Predicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.detect(predicate);
        }
    }

    @Override
    public \<P> V detectWith(Predicate2\<? super V, ? super P> predicate, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.detectWith(predicate, parameter);
        }
    }

    @Override
    public Optional\<V> detectOptional(Predicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.detectOptional(predicate);
        }
    }

    @Override
    public \<P> Optional\<V> detectWithOptional(Predicate2\<? super V, ? super P> predicate, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.detectWithOptional(predicate, parameter);
        }
    }

    @Override
    public V detectIfNone(Predicate\<? super V> predicate, Function0\<? extends V> function)
    {
        synchronized (this.lock)
        {
            return this.map.detectIfNone(predicate, function);
        }
    }

    @Override
    public \<P> V detectWithIfNone(Predicate2\<? super V, ? super P> predicate, P parameter, Function0\<? extends V> function)
    {
        synchronized (this.lock)
        {
            return this.map.detectWithIfNone(predicate, parameter, function);
        }
    }

    @Override
    public int count(Predicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.count(predicate);
        }
    }

    @Override
    public \<P> int countWith(Predicate2\<? super V, ? super P> predicate, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.countWith(predicate, parameter);
        }
    }

    @Override
    public boolean anySatisfy(Predicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.anySatisfy(predicate);
        }
    }

    @Override
    public \<P> boolean anySatisfyWith(Predicate2\<? super V, ? super P> predicate, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.anySatisfyWith(predicate, parameter);
        }
    }

    @Override
    public boolean allSatisfy(Predicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.allSatisfy(predicate);
        }
    }

    @Override
    public \<P> boolean allSatisfyWith(Predicate2\<? super V, ? super P> predicate, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.allSatisfyWith(predicate, parameter);
        }
    }

    @Override
    public boolean noneSatisfy(Predicate\<? super V> predicate)
    {
        synchronized (this.lock)
        {
            return this.map.noneSatisfy(predicate);
        }
    }

    @Override
    public \<P> boolean noneSatisfyWith(Predicate2\<? super V, ? super P> predicate, P parameter)
    {
        synchronized (this.lock)
        {
            return this.map.noneSatisfyWith(predicate, parameter);
        }
    }

    @Override
    public \<IV> IV injectInto(IV injectedValue, Function2\<? super IV, ? super V, ? extends IV> function)
    {
        synchronized (this.lock)
        {
            return this.map.injectInto(injectedValue, function);
        }
    }

    @Override
    public int injectInto(int injectedValue, IntObjectToIntFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.injectInto(injectedValue, function);
        }
    }

    @Override
    public long injectInto(long injectedValue, LongObjectToLongFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.injectInto(injectedValue, function);
        }
    }

    @Override
    public float injectInto(float injectedValue, FloatObjectToFloatFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.injectInto(injectedValue, function);
        }
    }

    @Override
    public double injectInto(double injectedValue, DoubleObjectToDoubleFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.injectInto(injectedValue, function);
        }
    }

    @Override
    public \<R extends Collection\<V>\> R into(R target)
    {
        synchronized (this.lock)
        {
            return this.map.into(target);
        }
    }

    @Override
    public MutableList\<V> toList()
    {
        synchronized (this.lock)
        {
            return this.map.toList();
        }
    }

    @Override
    public MutableList\<V> toSortedList()
    {
        synchronized (this.lock)
        {
            return this.map.toSortedList();
        }
    }

    @Override
    public MutableList\<V> toSortedList(Comparator\<? super V> comparator)
    {
        synchronized (this.lock)
        {
            return this.map.toSortedList(comparator);
        }
    }

    @Override
    public \<VV extends Comparable\<? super VV>\> MutableList\<V> toSortedListBy(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.toSortedListBy(function);
        }
    }

    @Override
    public MutableSet\<V> toSet()
    {
        synchronized (this.lock)
        {
            return this.map.toSet();
        }
    }

    @Override
    public MutableSortedSet\<V> toSortedSet()
    {
        synchronized (this.lock)
        {
            return this.map.toSortedSet();
        }
    }

    @Override
    public MutableSortedSet\<V> toSortedSet(Comparator\<? super V> comparator)
    {
        synchronized (this.lock)
        {
            return this.map.toSortedSet(comparator);
        }
    }

    @Override
    public \<VV extends Comparable\<? super VV>\> MutableSortedSet\<V> toSortedSetBy(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.toSortedSetBy(function);
        }
    }

    @Override
    public MutableBag\<V> toBag()
    {
        synchronized (this.lock)
        {
            return this.map.toBag();
        }
    }

    @Override
    public MutableSortedBag\<V> toSortedBag()
    {
        synchronized (this.lock)
        {
            return this.map.toSortedBag();
        }
    }

    @Override
    public MutableSortedBag\<V> toSortedBag(Comparator\<? super V> comparator)
    {
        synchronized (this.lock)
        {
            return this.map.toSortedBag(comparator);
        }
    }

    @Override
    public \<VV extends Comparable\<? super VV>\> MutableSortedBag\<V> toSortedBagBy(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.toSortedBagBy(function);
        }
    }

    @Override
    public \<NK, NV> MutableMap\<NK, NV> toMap(Function\<? super V, ? extends NK> keyFunction, Function\<? super V, ? extends NV> valueFunction)
    {
        synchronized (this.lock)
        {
            return this.map.toMap(keyFunction, valueFunction);
        }
    }

    @Override
    public \<NK, NV, R extends Map\<NK, NV>\> R toMap(Function\<? super V, ? extends NK> keyFunction, Function\<? super V, ? extends NV> valueFunction, R target)
    {
        synchronized (this.lock)
        {
            return this.map.toMap(keyFunction, valueFunction, target);
        }
    }

    @Override
    public \<NK, NV> MutableSortedMap\<NK, NV> toSortedMap(Function\<? super V, ? extends NK> keyFunction, Function\<? super V, ? extends NV> valueFunction)
    {
        synchronized (this.lock)
        {
            return this.map.toSortedMap(keyFunction, valueFunction);
        }
    }

    @Override
    public \<NK, NV> MutableSortedMap\<NK, NV> toSortedMap(Comparator\<? super NK> comparator, Function\<? super V, ? extends NK> keyFunction, Function\<? super V, ? extends NV> valueFunction)
    {
        synchronized (this.lock)
        {
            return this.map.toSortedMap(comparator, keyFunction, valueFunction);
        }
    }

    @Override
    public \<KK extends Comparable\<? super KK>, NK, NV> MutableSortedMap\<NK, NV> toSortedMapBy(Function\<? super NK, KK> sortBy, Function\<? super V, ? extends NK> keyFunction, Function\<? super V, ? extends NV> valueFunction)
    {
        synchronized (this.lock)
        {
            return this.map.toSortedMapBy(sortBy, keyFunction, valueFunction);
        }
    }

    @Override
    public \<NK, NV> MutableBiMap\<NK, NV> toBiMap(Function\<? super V, ? extends NK> keyFunction, Function\<? super V, ? extends NV> valueFunction)
    {
        synchronized (this.lock)
        {
            return this.map.toBiMap(keyFunction, valueFunction);
        }
    }

    @Override
    public ImmutableList\<V> toImmutableList()
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableList();
        }
    }

    @Override
    public ImmutableSet\<V> toImmutableSet()
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSet();
        }
    }

    @Override
    public ImmutableBag\<V> toImmutableBag()
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableBag();
        }
    }

    @Override
    public ImmutableList\<V> toImmutableSortedList()
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSortedList();
        }
    }

    @Override
    public ImmutableList\<V> toImmutableSortedList(Comparator\<? super V> comparator)
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSortedList(comparator);
        }
    }

    @Override
    public \<VV extends Comparable\<? super VV>\> ImmutableList\<V> toImmutableSortedListBy(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSortedListBy(function);
        }
    }

    @Override
    public ImmutableSortedSet\<V> toImmutableSortedSet()
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSortedSet();
        }
    }

    @Override
    public ImmutableSortedSet\<V> toImmutableSortedSet(Comparator\<? super V> comparator)
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSortedSet(comparator);
        }
    }

    @Override
    public \<VV extends Comparable\<? super VV>\> ImmutableSortedSet\<V> toImmutableSortedSetBy(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSortedSetBy(function);
        }
    }

    @Override
    public ImmutableSortedBag\<V> toImmutableSortedBag()
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSortedBag();
        }
    }

    @Override
    public ImmutableSortedBag\<V> toImmutableSortedBag(Comparator\<? super V> comparator)
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSortedBag(comparator);
        }
    }

    @Override
    public \<VV extends Comparable\<? super VV>\> ImmutableSortedBag\<V> toImmutableSortedBagBy(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.toImmutableSortedBagBy(function);
        }
    }

    @Override
    public LazyIterable\<V> asLazy()
    {
        synchronized (this.lock)
        {
            return this.map.asLazy();
        }
    }

    @Override
    public Object[] toArray()
    {
        synchronized (this.lock)
        {
            return this.map.toArray();
        }
    }

    @Override
    public \<T> T[] toArray(T[] a)
    {
        synchronized (this.lock)
        {
            return this.map.toArray(a);
        }
    }

    @Override
    public V min(Comparator\<? super V> comparator)
    {
        synchronized (this.lock)
        {
            return this.map.min(comparator);
        }
    }

    @Override
    public V max(Comparator\<? super V> comparator)
    {
        synchronized (this.lock)
        {
            return this.map.max(comparator);
        }
    }

    @Override
    public V min()
    {
        synchronized (this.lock)
        {
            return this.map.min();
        }
    }

    @Override
    public V max()
    {
        synchronized (this.lock)
        {
            return this.map.max();
        }
    }

    @Override
    public \<VV extends Comparable\<? super VV>\> V maxBy(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.maxBy(function);
        }
    }

    @Override
    public \<VV extends Comparable\<? super VV>\> V minBy(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.minBy(function);
        }
    }

    @Override
    public long sumOfInt(IntFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.sumOfInt(function);
        }
    }

    @Override
    public double sumOfFloat(FloatFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.sumOfFloat(function);
        }
    }

    @Override
    public long sumOfLong(LongFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.sumOfLong(function);
        }
    }

    @Override
    public double sumOfDouble(DoubleFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.sumOfDouble(function);
        }
    }

    @Override
    public \<V1> MutableObjectLongMap\<V1> sumByInt(Function\<? super V, ? extends V1> groupBy, IntFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.sumByInt(groupBy, function);
        }
    }

    @Override
    public \<V1> MutableObjectDoubleMap\<V1> sumByFloat(Function\<? super V, ? extends V1> groupBy, FloatFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.sumByFloat(groupBy, function);
        }
    }

    @Override
    public \<V1> MutableObjectLongMap\<V1> sumByLong(Function\<? super V, ? extends V1> groupBy, LongFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.sumByLong(groupBy, function);
        }
    }

    @Override
    public \<V1> MutableObjectDoubleMap\<V1> sumByDouble(Function\<? super V, ? extends V1> groupBy, DoubleFunction\<? super V> function)
    {
        synchronized (this.lock)
        {
            return this.map.sumByDouble(groupBy, function);
        }
    }

    @Override
    public Mutable<name>Set keySet()
    {
        synchronized (this.lock)
        {
            return Synchronized<name>Set.of(this.map.keySet(), this.lock);
        }
    }

    @Override
    public Collection\<V> values()
    {
        synchronized (this.lock)
        {
            return SynchronizedMutableCollection.of(CollectionAdapter.adapt(this.map.values()), this.lock);
        }
    }

    @Override
    public Lazy<name>Iterable keysView()
    {
        synchronized (this.lock)
        {
            return Synchronized<name>Iterable.of(this.map.keysView(), this.lock).asLazy();
        }
    }

    @Override
    public RichIterable\<<name>ObjectPair\<V>\> keyValuesView()
    {
        synchronized (this.lock)
        {
            return SynchronizedRichIterable.of(this.map.keyValuesView(), this.lock).asLazy();
        }
    }

    @Override
    public MutableObject<name>Map\<V> flipUniqueValues()
    {
        synchronized (this.lock)
        {
            return this.map.flipUniqueValues();
        }
    }

    @Override
    public boolean equals(Object obj)
    {
        synchronized (this.lock)
        {
            return this.map.equals(obj);
        }
    }

    @Override
    public int hashCode()
    {
        synchronized (this.lock)
        {
            return this.map.hashCode();
        }
    }

    @Override
    public String toString()
    {
        synchronized (this.lock)
        {
            return this.map.toString();
        }
    }

    @Override
    public String makeString()
    {
        synchronized (this.lock)
        {
            return this.map.makeString();
        }
    }

    @Override
    public String makeString(String separator)
    {
        synchronized (this.lock)
        {
            return this.map.makeString(separator);
        }
    }

    @Override
    public String makeString(String start, String separator, String end)
    {
        synchronized (this.lock)
        {
            return this.map.makeString(start, separator, end);
        }
    }

    @Override
    public void appendString(Appendable appendable)
    {
        synchronized (this.lock)
        {
            this.map.appendString(appendable);
        }
    }

    @Override
    public void appendString(Appendable appendable, String separator)
    {
        synchronized (this.lock)
        {
            this.map.appendString(appendable, separator);
        }
    }

    @Override
    public void appendString(Appendable appendable, String start, String separator, String end)
    {
        synchronized (this.lock)
        {
            this.map.appendString(appendable, start, separator, end);
        }
    }

    @Override
    public \<VV> MutableBagMultimap\<VV, V> groupBy(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.groupBy(function);
        }
    }

    @Override
    public \<VV, R extends MutableMultimap\<VV, V>\> R groupBy(Function\<? super V, ? extends VV> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.groupBy(function, target);
        }
    }

    @Override
    public \<VV> MutableBagMultimap\<VV, V> groupByEach(Function\<? super V, ? extends Iterable\<VV>\> function)
    {
        synchronized (this.lock)
        {
            return this.map.groupByEach(function);
        }
    }

    @Override
    public \<VV, R extends MutableMultimap\<VV, V>\> R groupByEach(Function\<? super V, ? extends Iterable\<VV>\> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.groupByEach(function, target);
        }
    }

    @Override
    public \<VV> MutableMap\<VV, V> groupByUniqueKey(Function\<? super V, ? extends VV> function)
    {
        synchronized (this.lock)
        {
            return this.map.groupByUniqueKey(function);
        }
    }

    @Override
    public \<VV, R extends MutableMapIterable\<VV, V>\> R groupByUniqueKey(Function\<? super V, ? extends VV> function, R target)
    {
        synchronized (this.lock)
        {
            return this.map.groupByUniqueKey(function, target);
        }
    }

    /**
     * @deprecated in 7.0. Use {@link OrderedIterable#zip(Iterable)} instead.
     */
    @Deprecated
    @Override
    public \<S> MutableBag\<Pair\<V, S>\> zip(Iterable\<S> that)
    {
        synchronized (this.lock)
        {
            return this.map.zip(that);
        }
    }

    @Override
    public \<S, R extends Collection\<Pair\<V, S>\>> R zip(Iterable\<S> that, R target)
    {
        synchronized (this.lock)
        {
            return this.map.zip(that, target);
        }
    }

    @Override
    public Mutable<name>ObjectMap\<V> withKeyValue(<type> key, V value)
    {
        synchronized (this.lock)
        {
            this.map.withKeyValue(key, value);
        }
        return this;
    }

    @Override
    public Mutable<name>ObjectMap\<V> withoutKey(<type> key)
    {
        synchronized (this.lock)
        {
            this.map.withoutKey(key);
        }
        return this;
    }

    @Override
    public Mutable<name>ObjectMap\<V> withoutAllKeys(<name>Iterable keys)
    {
        synchronized (this.lock)
        {
            this.map.withoutAllKeys(keys);
        }
        return this;
    }

    @Override
    public Mutable<name>ObjectMap\<V> asUnmodifiable()
    {
        synchronized (this.lock)
        {
            return new Unmodifiable<name>ObjectMap\<>(this);
        }
    }

    @Override
    public Mutable<name>ObjectMap\<V> asSynchronized()
    {
        return this;
    }

    @Override
    public Immutable<name>ObjectMap\<V> toImmutable()
    {
        synchronized (this.lock)
        {
            return <name>ObjectMaps.immutable.withAll(this);
        }
    }

    @Override
    public void forEach(Procedure\<? super V> procedure)
    {
        this.each(procedure);
    }

    @Override
    public void each(Procedure\<? super V> procedure)
    {
        synchronized (this.lock)
        {
            this.map.forEach(procedure);
        }
    }

    @Override
    public void forEachWithIndex(ObjectIntProcedure\<? super V> objectIntProcedure)
    {
        synchronized (this.lock)
        {
            this.map.forEachWithIndex(objectIntProcedure);
        }
    }

    @Override
    public \<P> void forEachWith(Procedure2\<? super V, ? super P> procedure, P parameter)
    {
        synchronized (this.lock)
        {
            this.map.forEachWith(procedure, parameter);
        }
    }

    /**
     * Must be called in a synchronized block.
     */
    @Override
    public Iterator\<V> iterator()
    {
        return this.map.iterator();
    }
}

>>

