public class CachingNameResolver extends Object implements NameResolver
Constructor and Description |
---|
CachingNameResolver(NameResolver resolver)
Creates a caching decorator for the given name resolver.
|
CachingNameResolver(NameResolver resolver,
org.apache.jackrabbit.spi.commons.conversion.GenerationalCache cache)
Creates a caching decorator for the given name resolver.
|
public CachingNameResolver(NameResolver resolver, org.apache.jackrabbit.spi.commons.conversion.GenerationalCache cache)
resolver
- decorated name resolvercache
- generational cachepublic CachingNameResolver(NameResolver resolver)
resolver
- name resolverpublic Name getQName(String jcrName) throws IllegalNameException, javax.jcr.NamespaceException
Name
for the given prefixed JCR name. The name
is first looked up form the generational cache and the call gets
delegated to the decorated name resolver only if the cache misses.getQName
in interface NameResolver
jcrName
- A JCR name String.Name
object.IllegalNameException
- if the JCR name format is invalidjavax.jcr.NamespaceException
- if the namespace prefix can not be resolvedpublic String getJCRName(Name name) throws javax.jcr.NamespaceException
Name
. The name
is first looked up form the generational cache and the call gets
delegated to the decorated name resolver only if the cache misses.getJCRName
in interface NameResolver
name
- The name object.prefix:localName
.javax.jcr.NamespaceException
- if the namespace URI can not be resolvedCopyright © 2004-2020 The Apache Software Foundation. All Rights Reserved.