|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jackrabbit.core.nodetype.BitsetENTCacheImpl
public class BitsetENTCacheImpl
Implements an effective node type cache that uses a bit set for storing the information about participating node types in a set.
Nested Class Summary |
---|
Nested classes/interfaces inherited from interface org.apache.jackrabbit.core.nodetype.EffectiveNodeTypeCache |
---|
EffectiveNodeTypeCache.Key |
Method Summary | |
---|---|
Object |
clone()
|
boolean |
contains(EffectiveNodeTypeCache.Key key)
Checks if the effective node type for the given key exists. |
void |
dump(PrintStream ps)
Dumps the state of this instance in a human readable format for diagnostic purposes. |
EffectiveNodeTypeCache.Key |
findBest(EffectiveNodeTypeCache.Key key)
Searches the best key k for which the given key is a super
set, i.e. for which EffectiveNodeTypeCache.contains(Key) } returns
true . |
EffectiveNodeType |
get(EffectiveNodeTypeCache.Key key)
Returns the effective node type for the given key or null if
the desired node type is not cached. |
EffectiveNodeTypeCache.Key |
getKey(Name[] ntNames)
Returns a key for an effective node type that consists of the given node type names. |
void |
invalidate(Name name)
Removes all effective node types that are aggregated with the node type of the given name. |
void |
put(EffectiveNodeType ent)
Puts an effective node type to the cache. |
void |
put(EffectiveNodeTypeCache.Key key,
EffectiveNodeType ent)
Puts an effective node type to the cache for the given key. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public EffectiveNodeTypeCache.Key getKey(Name[] ntNames)
getKey
in interface EffectiveNodeTypeCache
ntNames
- the array of node type names for the effective node type
public void put(EffectiveNodeType ent)
put
in interface EffectiveNodeTypeCache
ent
- the effective node type to put to the cachepublic void put(EffectiveNodeTypeCache.Key key, EffectiveNodeType ent)
put
in interface EffectiveNodeTypeCache
key
- the key for the effective node typeent
- the effective node type to put to the cachepublic EffectiveNodeTypeCache.Key findBest(EffectiveNodeTypeCache.Key key)
key
is a super
set, i.e. for which EffectiveNodeTypeCache.contains(Key)
} returns
true
. If an already cached effective node type matches the
key it is returned.
findBest
in interface EffectiveNodeTypeCache
key
- the key for which the subkey is to be searched
null
if no key could be found.public void invalidate(Name name)
invalidate
in interface EffectiveNodeTypeCache
name
- the name of the node type.public boolean contains(EffectiveNodeTypeCache.Key key)
contains
in interface EffectiveNodeTypeCache
key
- the key to check
true
if the effective node type is cached;
false
otherwise.public EffectiveNodeType get(EffectiveNodeTypeCache.Key key)
null
if
the desired node type is not cached.
get
in interface EffectiveNodeTypeCache
key
- the key for the effective node type.
null
public Object clone()
clone
in interface EffectiveNodeTypeCache
clone
in class Object
public void dump(PrintStream ps)
dump
in interface Dumpable
ps
- stream to dump state to
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |