- Type Parameters:
E
-
- All Superinterfaces:
JenaMapSetCommon<E>
- All Known Subinterfaces:
FastTripleBunch
,JenaSetHashOptimized<E>
,NodeToTriplesMap
,TripleBunch
- All Known Implementing Classes:
ArrayBunch
,FastArrayBunch
,FastHashedTripleBunch
,FastHashSet
,HashCommonSet
,HashedTripleBunch
,NodeToTriplesMapMem
Set interface specialized for the use cases in triple store implementations.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addUnchecked
(E key) Add the key to the set without checking if it is already present.boolean
Add the key to the set if it is not already present.Methods inherited from interface org.apache.jena.mem2.collection.JenaMapSetCommon
anyMatch, clear, containsKey, isEmpty, keyIterator, keySpliterator, keyStream, keyStreamParallel, removeUnchecked, size, tryRemove
-
Method Details
-
tryAdd
Add the key to the set if it is not already present.- Parameters:
key
- the key to add- Returns:
- true if the key was added, false if it was already present
-
addUnchecked
Add the key to the set without checking if it is already present. Attention: This method must only be used if it is guaranteed that the key is not already present.- Parameters:
key
- the key to add
-