Class SynchronizedCharShortMap
- java.lang.Object
-
- org.eclipse.collections.impl.map.mutable.primitive.SynchronizedCharShortMap
-
- All Implemented Interfaces:
Serializable,CharShortMap,MutableCharShortMap,MutableShortValuesMap,ShortValuesMap,PrimitiveIterable,ShortIterable
public class SynchronizedCharShortMap extends Object implements MutableCharShortMap, Serializable
A synchronized view of aMutableCharShortMap. It is imperative that the user manually synchronize on the collection when iterating over it using theMutableShortIteratoras perCollections.synchronizedCollection(Collection).This file was automatically generated from template file synchronizedPrimitivePrimitiveMap.stg.
- Since:
- 3.1.
- See Also:
MutableCharShortMap.asSynchronized(),MutableMap.asSynchronized(), Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SynchronizedCharShortMap(MutableCharShortMap map)SynchronizedCharShortMap(MutableCharShortMap map, Object newLock)
-
Method Summary
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.CharShortMap
injectIntoKeyValue
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.MutableCharShortMap
withAllKeyValues
-
Methods inherited from interface org.eclipse.collections.api.ShortIterable
averageIfEmpty, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, containsAny, containsAny, containsNone, containsNone, flatCollect, forEach, injectIntoBoolean, injectIntoByte, injectIntoChar, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, injectIntoShort, medianIfEmpty, reduce, reduceIfEmpty, reject, select, summaryStatistics, toSortedList, toSortedListBy, toSortedListBy
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.ShortValuesMap
tap
-
-
-
-
Constructor Detail
-
SynchronizedCharShortMap
public SynchronizedCharShortMap(MutableCharShortMap map)
-
SynchronizedCharShortMap
public SynchronizedCharShortMap(MutableCharShortMap map, Object newLock)
-
-
Method Detail
-
clear
public void clear()
- Specified by:
clearin interfaceMutableShortValuesMap
-
put
public void put(char key, short value)- Specified by:
putin interfaceMutableCharShortMap
-
putPair
public void putPair(CharShortPair keyValuePair)
- Specified by:
putPairin interfaceMutableCharShortMap
-
putAll
public void putAll(CharShortMap map)
- Specified by:
putAllin interfaceMutableCharShortMap
-
updateValues
public void updateValues(CharShortToShortFunction function)
- Specified by:
updateValuesin interfaceMutableCharShortMap
-
removeKey
public void removeKey(char key)
- Specified by:
removeKeyin interfaceMutableCharShortMap
-
remove
public void remove(char key)
- Specified by:
removein interfaceMutableCharShortMap
-
removeKeyIfAbsent
public short removeKeyIfAbsent(char key, short value)- Specified by:
removeKeyIfAbsentin interfaceMutableCharShortMap
-
getIfAbsentPut
public short getIfAbsentPut(char key, short value)- Specified by:
getIfAbsentPutin interfaceMutableCharShortMap
-
getAndPut
public short getAndPut(char key, short putValue, short defaultValue)- Specified by:
getAndPutin interfaceMutableCharShortMap
-
getIfAbsentPut
public short getIfAbsentPut(char key, ShortFunction0 function)- Specified by:
getIfAbsentPutin interfaceMutableCharShortMap
-
getIfAbsentPutWithKey
public short getIfAbsentPutWithKey(char key, CharToShortFunction function)- Specified by:
getIfAbsentPutWithKeyin interfaceMutableCharShortMap
-
getIfAbsentPutWith
public <P> short getIfAbsentPutWith(char key, ShortFunction<? super P> function, P parameter)- Specified by:
getIfAbsentPutWithin interfaceMutableCharShortMap
-
updateValue
public short updateValue(char key, short initialValueIfAbsent, ShortToShortFunction function)- Specified by:
updateValuein interfaceMutableCharShortMap
-
get
public short get(char key)
- Specified by:
getin interfaceCharShortMap
-
getIfAbsent
public short getIfAbsent(char key, short ifAbsent)- Specified by:
getIfAbsentin interfaceCharShortMap
-
getOrThrow
public short getOrThrow(char key)
- Specified by:
getOrThrowin interfaceCharShortMap
-
containsKey
public boolean containsKey(char key)
- Specified by:
containsKeyin interfaceCharShortMap
-
containsValue
public boolean containsValue(short value)
- Specified by:
containsValuein interfaceShortValuesMap
-
forEachValue
public void forEachValue(ShortProcedure procedure)
- Specified by:
forEachValuein interfaceShortValuesMap
-
forEachKey
public void forEachKey(CharProcedure procedure)
- Specified by:
forEachKeyin interfaceCharShortMap
-
forEachKeyValue
public void forEachKeyValue(CharShortProcedure procedure)
- Specified by:
forEachKeyValuein interfaceCharShortMap
-
keysView
public LazyCharIterable keysView()
- Specified by:
keysViewin interfaceCharShortMap
-
keyValuesView
public RichIterable<CharShortPair> keyValuesView()
- Specified by:
keyValuesViewin interfaceCharShortMap
-
flipUniqueValues
public MutableShortCharMap flipUniqueValues()
- Specified by:
flipUniqueValuesin interfaceCharShortMap- Specified by:
flipUniqueValuesin interfaceMutableCharShortMap
-
select
public MutableCharShortMap select(CharShortPredicate predicate)
- Specified by:
selectin interfaceCharShortMap- Specified by:
selectin interfaceMutableCharShortMap
-
reject
public MutableCharShortMap reject(CharShortPredicate predicate)
- Specified by:
rejectin interfaceCharShortMap- Specified by:
rejectin interfaceMutableCharShortMap
-
shortIterator
public MutableShortIterator shortIterator()
This must be manually synchronized by the developer.- Specified by:
shortIteratorin interfaceMutableShortValuesMap- Specified by:
shortIteratorin interfaceShortIterable
-
each
public void each(ShortProcedure procedure)
- Specified by:
eachin interfaceShortIterable- Since:
- 7.0.
-
count
public int count(ShortPredicate predicate)
- Specified by:
countin interfaceShortIterable
-
anySatisfy
public boolean anySatisfy(ShortPredicate predicate)
- Specified by:
anySatisfyin interfaceShortIterable
-
allSatisfy
public boolean allSatisfy(ShortPredicate predicate)
- Specified by:
allSatisfyin interfaceShortIterable
-
noneSatisfy
public boolean noneSatisfy(ShortPredicate predicate)
- Specified by:
noneSatisfyin interfaceShortIterable
-
select
public MutableShortBag select(ShortPredicate predicate)
- Specified by:
selectin interfaceMutableShortValuesMap- Specified by:
selectin interfaceShortIterable- Specified by:
selectin interfaceShortValuesMap
-
reject
public MutableShortBag reject(ShortPredicate predicate)
- Specified by:
rejectin interfaceMutableShortValuesMap- Specified by:
rejectin interfaceShortIterable- Specified by:
rejectin interfaceShortValuesMap
-
collect
public <V> MutableBag<V> collect(ShortToObjectFunction<? extends V> function)
- Specified by:
collectin interfaceMutableShortValuesMap- Specified by:
collectin interfaceShortIterable- Specified by:
collectin interfaceShortValuesMap
-
detectIfNone
public short detectIfNone(ShortPredicate predicate, short ifNone)
- Specified by:
detectIfNonein interfaceShortIterable
-
sum
public long sum()
- Specified by:
sumin interfaceShortIterable
-
max
public short max()
- Specified by:
maxin interfaceShortIterable
-
maxIfEmpty
public short maxIfEmpty(short defaultValue)
- Specified by:
maxIfEmptyin interfaceShortIterable
-
min
public short min()
- Specified by:
minin interfaceShortIterable
-
minIfEmpty
public short minIfEmpty(short defaultValue)
- Specified by:
minIfEmptyin interfaceShortIterable
-
average
public double average()
- Specified by:
averagein interfaceShortIterable
-
median
public double median()
- Specified by:
medianin interfaceShortIterable
-
addToValue
public short addToValue(char key, short toBeAdded)- Specified by:
addToValuein interfaceMutableCharShortMap
-
toSortedArray
public short[] toSortedArray()
- Specified by:
toSortedArrayin interfaceShortIterable
-
toSortedList
public MutableShortList toSortedList()
- Specified by:
toSortedListin interfaceShortIterable
-
toArray
public short[] toArray()
- Specified by:
toArrayin interfaceShortIterable
-
toArray
public short[] toArray(short[] target)
- Specified by:
toArrayin interfaceShortIterable
-
contains
public boolean contains(short value)
- Specified by:
containsin interfaceShortIterable
-
containsAll
public boolean containsAll(short... source)
- Specified by:
containsAllin interfaceShortIterable
-
containsAll
public boolean containsAll(ShortIterable source)
- Specified by:
containsAllin interfaceShortIterable
-
toList
public MutableShortList toList()
- Specified by:
toListin interfaceShortIterable
-
toSet
public MutableShortSet toSet()
- Specified by:
toSetin interfaceShortIterable
-
toBag
public MutableShortBag toBag()
- Specified by:
toBagin interfaceShortIterable
-
asLazy
public LazyShortIterable asLazy()
- Specified by:
asLazyin interfaceShortIterable
-
withKeyValue
public MutableCharShortMap withKeyValue(char key, short value)
- Specified by:
withKeyValuein interfaceMutableCharShortMap
-
withoutKey
public MutableCharShortMap withoutKey(char key)
- Specified by:
withoutKeyin interfaceMutableCharShortMap
-
withoutAllKeys
public MutableCharShortMap withoutAllKeys(CharIterable keys)
- Specified by:
withoutAllKeysin interfaceMutableCharShortMap
-
asUnmodifiable
public MutableCharShortMap asUnmodifiable()
- Specified by:
asUnmodifiablein interfaceMutableCharShortMap
-
asSynchronized
public MutableCharShortMap asSynchronized()
- Specified by:
asSynchronizedin interfaceMutableCharShortMap
-
toImmutable
public ImmutableCharShortMap toImmutable()
- Specified by:
toImmutablein interfaceCharShortMap
-
size
public int size()
- Specified by:
sizein interfacePrimitiveIterable
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmptyin interfacePrimitiveIterable
-
notEmpty
public boolean notEmpty()
- Specified by:
notEmptyin interfacePrimitiveIterable
-
keySet
public MutableCharSet keySet()
- Specified by:
keySetin interfaceCharShortMap
-
values
public MutableShortCollection values()
- Specified by:
valuesin interfaceShortValuesMap
-
equals
public boolean equals(Object otherMap)
- Specified by:
equalsin interfaceCharShortMap- Overrides:
equalsin classObject
-
hashCode
public int hashCode()
- Specified by:
hashCodein interfaceCharShortMap- Overrides:
hashCodein classObject
-
toString
public String toString()
- Specified by:
toStringin interfaceCharShortMap- Specified by:
toStringin interfacePrimitiveIterable- Overrides:
toStringin classObject
-
makeString
public String makeString()
- Specified by:
makeStringin interfacePrimitiveIterable
-
makeString
public String makeString(String separator)
- Specified by:
makeStringin interfacePrimitiveIterable
-
makeString
public String makeString(String start, String separator, String end)
- Specified by:
makeStringin interfacePrimitiveIterable
-
appendString
public void appendString(Appendable appendable)
- Specified by:
appendStringin interfacePrimitiveIterable
-
appendString
public void appendString(Appendable appendable, String separator)
- Specified by:
appendStringin interfacePrimitiveIterable
-
appendString
public void appendString(Appendable appendable, String start, String separator, String end)
- Specified by:
appendStringin interfacePrimitiveIterable
-
injectInto
public <T> T injectInto(T injectedValue, ObjectShortToObjectFunction<? super T,? extends T> function)- Specified by:
injectIntoin interfaceShortIterable
-
chunk
public RichIterable<ShortIterable> chunk(int size)
- Specified by:
chunkin interfaceShortIterable
-
-