Package org.apache.jena.mem
Interface BunchMap
- All Known Implementing Classes:
HashedBunchMap
,WrappedHashMap
public interface BunchMap
A pruned (and slightly stewed) version of Map, containing just those operations
required by NodeToTriplesMaps. BunchMaps contain only TripleBunch's.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
Clear this map: all entries are removed.Answer the TripleBunch associated withkey
, ornull
if there isn't one.getOrSet
(Object key, Function<Object, TripleBunch> setter) Get thekey
and return the value found there; if nothing, calculate thevalue
and insert.Answer an iterator over all the keys in this map.void
put
(Object key, TripleBunch value) Associatekey
andvalue
.void
Remove any association forkey
;get
on this key will now delivernull
.long
size()
The number of items in the bunch.
-
Method Details
-
clear
void clear()Clear this map: all entries are removed. -
size
long size()The number of items in the bunch. -
get
Answer the TripleBunch associated withkey
, ornull
if there isn't one. -
put
Associatekey
andvalue
. Any existing association ofkey
is lost.get
on this key will now deliver this value. -
getOrSet
Get thekey
and return the value found there; if nothing, calculate thevalue
and insert. Return the value now the slot. -
remove
Remove any association forkey
;get
on this key will now delivernull
. -
keyIterator
ExtendedIterator<Object> keyIterator()Answer an iterator over all the keys in this map.
-