|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jackrabbit.spi.commons.conversion.CachingPathResolver
public class CachingPathResolver
Path resolver decorator that uses a generational cache to speed up parsing and formatting of JCR paths. Uncached paths are resolved using the underlying decorated path resolver.
Constructor Summary | |
---|---|
CachingPathResolver(PathResolver resolver)
Creates a caching decorator for the given path resolver. |
|
CachingPathResolver(PathResolver resolver,
org.apache.jackrabbit.spi.commons.conversion.GenerationalCache cache)
Creates a caching decorator for the given path resolver. |
Method Summary | |
---|---|
String |
getJCRPath(Path path)
Returns the JCR path String for the given Path . |
Path |
getQPath(String path)
Returns the Path object for the given JCR path String. |
Path |
getQPath(String path,
boolean normalizeIdentifier)
Returns the path object for the given JCR path string. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CachingPathResolver(PathResolver resolver, org.apache.jackrabbit.spi.commons.conversion.GenerationalCache cache)
resolver
- decorated path resolvercache
- generational cachepublic CachingPathResolver(PathResolver resolver)
resolver
- name resolverMethod Detail |
---|
public Path getQPath(String path) throws MalformedPathException, IllegalNameException, NamespaceException
Path
object for the given JCR path String.
The path is first looked up form the generational cache and the call gets
delegated to the decorated path resolver only if the cache misses.
getQPath
in interface PathResolver
path
- A JCR path String.
Path
object.
MalformedPathException
- if the JCR path format is invalid
IllegalNameException
- if any of the JCR names contained in the
path are invalid.
NamespaceException
- if a namespace prefix can not be resolved.PathResolver.getQPath(String)
public Path getQPath(String path, boolean normalizeIdentifier) throws MalformedPathException, IllegalNameException, NamespaceException
PathResolver
getQPath
in interface PathResolver
path
- prefixed JCR path
Path
object.
MalformedPathException
- if the JCR path format is invalid.
IllegalNameException
- if any of the JCR names contained in the path are invalid.
NamespaceException
- if a namespace prefix can not be resolved.PathResolver.getQPath(String, boolean)
public String getJCRPath(Path path) throws NamespaceException
Path
. The path
is first looked up form the generational cache and the call gets
delegated to the decorated path resolver only if the cache misses.
getJCRPath
in interface PathResolver
path
- A Path
object.
NamespaceException
- if a namespace URI can not be resolved.PathResolver.getJCRPath(org.apache.jackrabbit.spi.Path)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |