public final class Util extends Object
| Modifier and Type | Method and Description |
|---|---|
static String |
escape(String path)
Escapes a JCR path such that it can be used in a XPath query
|
static String |
replace(String string,
String target,
String replacement)
Replace every occurrence of
target in string with
replacement. |
static boolean |
supportOption(javax.jcr.Node node,
String option)
The repository's support option definition.
|
static GregorianCalendar |
toCalendar(Calendar date)
Convert from
Calendar to a GregorianCalendar. |
public static GregorianCalendar toCalendar(Calendar date)
Calendar to a GregorianCalendar.date - date if it is an instance of GregorianCalendar.
Otherwise a new GregorianCalendar instance for date.public static String replace(String string, String target, String replacement)
target in string with
replacement.string - string to do replacement ontarget - string to search forreplacement - string to replace withpublic static String escape(String path)
path - public static boolean supportOption(javax.jcr.Node node,
String option)
throws javax.jcr.RepositoryException
node - JCR nodeoption - requested repository's optionjavax.jcr.RepositoryException - thrown when any error with repository was occurred.Copyright © 2009-2013 The Apache Software Foundation. All Rights Reserved.