Class BmLongSegmentSyncSet
- java.lang.Object
- 
- com._1c.g5.v8.bm.common.collections.BmLongSegmentSyncSet
 
- 
- All Implemented Interfaces:
- IBmLongSet
 
 public class BmLongSegmentSyncSet extends Object implements IBmLongSet A Long set with segment synchronization. Implementation limited only for put/get/remove operations. Iterations are not supported.
- 
- 
Nested Class Summary- 
Nested classes/interfaces inherited from interface com._1c.g5.v8.bm.common.collections.IBmLongSetIBmLongSet.Entry
 
- 
 - 
Field SummaryFields Modifier and Type Field Description protected longhashSalt
 - 
Constructor SummaryConstructors Constructor Description BmLongSegmentSyncSet(int segments)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(long key)Adds the specified element.voidaddAll(long[] array)Adds all the values from the specified array.voidaddAll(IBmLongSet values)Adds all the values from the specified collection.voidaddAll(Iterable<Long> values)Adds all the values from the specified collection.BmLongHashSetasMap()voidclear()Removes all the elements.booleancontains(long key)Checks if the set contains the specified element.List<Long>copyKeys()Iterable<IBmLongSet.Entry>entryIterator()Gets entry iterator.IBmLongSetgetMap(long key)BmLongHashSet[]getSegments()protected longhashSaltValue()booleanhaveItems()booleanisEmpty()Checks whether this set is empty.IBmLongIteratoriterator()Gets the long value iteratorCollection<Long>keys()Gets collection of elements.booleanremove(long key)Removes the specified element.voidremoveAll(Set<Long> set)intsize()Returns the number of elements in this set.
 
- 
- 
- 
Method Detail- 
hashSaltValueprotected long hashSaltValue() 
 - 
entryIteratorpublic Iterable<IBmLongSet.Entry> entryIterator() Description copied from interface:IBmLongSetGets entry iterator.- Specified by:
- entryIteratorin interface- IBmLongSet
- Returns:
- an entry iterator.
 
 - 
iteratorpublic IBmLongIterator iterator() Description copied from interface:IBmLongSetGets the long value iterator- Specified by:
- iteratorin interface- IBmLongSet
- Returns:
- The iterator of values. May not be null
 
 - 
clearpublic void clear() Description copied from interface:IBmLongSetRemoves all the elements.- Specified by:
- clearin interface- IBmLongSet
- See Also:
- IBmLongSet.isEmpty(),- IBmLongSet.size()
 
 - 
getMappublic IBmLongSet getMap(long key) 
 - 
containspublic boolean contains(long key) Description copied from interface:IBmLongSetChecks if the set contains the specified element.- Specified by:
- containsin interface- IBmLongSet
- Parameters:
- key- the element.
- Returns:
- trueif set contains the specified element,- falseotherwise.
 
 - 
addpublic void add(long key) Description copied from interface:IBmLongSetAdds the specified element.- Specified by:
- addin interface- IBmLongSet
- Parameters:
- key- the element to add.
 
 - 
removepublic boolean remove(long key) Description copied from interface:IBmLongSetRemoves the specified element.- Specified by:
- removein interface- IBmLongSet
- Parameters:
- key- the element to remove.
- Returns:
- trueif this set contained the specified element,- falseotherwise.
 
 - 
sizepublic int size() Description copied from interface:IBmLongSetReturns the number of elements in this set.- Specified by:
- sizein interface- IBmLongSet
- Returns:
- the number of elements in this set.
 
 - 
asMappublic BmLongHashSet asMap() 
 - 
getSegmentspublic BmLongHashSet[] getSegments() 
 - 
haveItemspublic boolean haveItems() 
 - 
addAllpublic void addAll(IBmLongSet values) Description copied from interface:IBmLongSetAdds all the values from the specified collection.- Specified by:
- addAllin interface- IBmLongSet
- Parameters:
- values- the collection of values to add.
 
 - 
addAllpublic void addAll(Iterable<Long> values) Description copied from interface:IBmLongSetAdds all the values from the specified collection.- Specified by:
- addAllin interface- IBmLongSet
- Parameters:
- values- the collection of values to add.
 
 - 
addAllpublic void addAll(long[] array) Description copied from interface:IBmLongSetAdds all the values from the specified array.- Specified by:
- addAllin interface- IBmLongSet
- Parameters:
- array- the array. May not be- null.
 
 - 
isEmptypublic boolean isEmpty() Description copied from interface:IBmLongSetChecks whether this set is empty.- Specified by:
- isEmptyin interface- IBmLongSet
- Returns:
- trueif this set has no elements,- falseotherwise.
- See Also:
- IBmLongSet.size()
 
 - 
keyspublic Collection<Long> keys() Description copied from interface:IBmLongSetGets collection of elements.- Specified by:
- keysin interface- IBmLongSet
- Returns:
- the collection of elements.
 
 
- 
 
-