Package com.evolveum.midpoint.util
Class QNameUtil
- java.lang.Object
- 
- com.evolveum.midpoint.util.QNameUtil
 
- 
 public class QNameUtil extends Object QName <-> URI conversion.Very simplistic but better than nothing. - Author:
- semancik
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classQNameUtil.PrefixedNamestatic classQNameUtil.QNameInfo
 - 
Field SummaryFields Modifier and Type Field Description static charDEFAULT_QNAME_URI_SEPARATOR_CHARstatic TraceLOGGER
 - 
Constructor SummaryConstructors Constructor Description QNameUtil()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Modifier and Type Method Description static booleancontains(Collection<? extends QName> col, QName qname)static booleancontains(QName[] array, QName qname)static Collection<QName>createCollection(QName... qnames)static StringescapeElementName(String name)static <V> VgetByQName(@NotNull Map<QName,V> map, @NotNull QName key)Finds value in the map by QName key usingmatch(QName, QName).static StringgetLocalPart(QName name)static booleanhasNamespace(@NotNull QName name)static booleanisPrefixUndeclared(String namespacePrefix)static booleanisQualified(QName name)static booleanisTolerateUndeclaredPrefixes()static booleanisUnqualified(String uri)static booleanisUnqualified(QName name)static booleanisUri(String string)static booleanisUriQName(@NotNull String maybeUri)static StringmarkPrefixAsUndeclared(String namespacePrefix)static booleanmatch(QName a, QName b)Matching with considering wildcard namespace (null).static booleanmatch(QName a, QName b, boolean caseInsensitive)static booleanmatchAny(QName nameToFind, Collection<? extends QName> names)static booleanmatches(QName qname, Node node)static booleanmatchUri(String uri1, String uri2)static booleanmatchWithUri(QName qname, String uri)Matches QName with a URI representation.static booleannoNamespace(@NotNull QName name)static QNamenullNamespace(QName qname)static QNameUtil.PrefixedNameparsePrefixedName(String name)static StringprettyPrint(QName... qnames)static QNameUtil.QNameInfoqnameToQnameInfo(QName name)static StringqNameToUri(QName qname)static StringqNameToUri(QName qname, boolean unqualifiedStartsWithHash)static StringqNameToUri(QName qname, boolean unqualifiedStartsWithHash, char separatorChar)static QNamequalifyIfNeeded(QName name, String defaultNamespace)static booleanremove(Collection<? extends QName> col, QName qname)static voidreportUndeclaredNamespacePrefix(String prefix, String context)static QNameresolveNs(QName a, Collection<QName> col)static voidsetTemporarilyTolerateUndeclaredPrefixes(Boolean value)static voidsetTolerateUndeclaredPrefixes(boolean value)static booleanunorderedCollectionMatch(Collection<QName> a, Collection<QName> b)static QNameunqualify(QName name)static @NotNull QNameuriToQName(@NotNull String uri, boolean allowUnqualified)static QNameuriToQName(String uri)static @NotNull QNameuriToQName(String uri, String defaultNamespace)static @NotNull QNameUtil.QNameInfouriToQNameInfo(@NotNull String uri, boolean allowUnqualified)
 
- 
- 
- 
Field Detail- 
LOGGERpublic static final Trace LOGGER 
 - 
DEFAULT_QNAME_URI_SEPARATOR_CHARpublic static final char DEFAULT_QNAME_URI_SEPARATOR_CHAR - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
qNameToUripublic static String qNameToUri(QName qname, boolean unqualifiedStartsWithHash, char separatorChar) 
 - 
noNamespacepublic static boolean noNamespace(@NotNull @NotNull QName name)
 - 
hasNamespacepublic static boolean hasNamespace(@NotNull @NotNull QName name)
 - 
getByQNamepublic static <V> V getByQName(@NotNull @NotNull Map<QName,V> map, @NotNull @NotNull QName key)Finds value in the map by QName key usingmatch(QName, QName). Fails if multiple matches are found. Returnsnullif no match is found.
 - 
parsePrefixedNamepublic static QNameUtil.PrefixedName parsePrefixedName(String name) 
 - 
qnameToQnameInfopublic static QNameUtil.QNameInfo qnameToQnameInfo(QName name) 
 - 
uriToQName@NotNull public static @NotNull QName uriToQName(@NotNull @NotNull String uri, boolean allowUnqualified) 
 - 
isUriQNamepublic static boolean isUriQName(@NotNull @NotNull String maybeUri)
 - 
uriToQNameInfo@NotNull public static @NotNull QNameUtil.QNameInfo uriToQNameInfo(@NotNull @NotNull String uri, boolean allowUnqualified) 
 - 
matchpublic static boolean match(QName a, QName b) Matching with considering wildcard namespace (null).
 - 
unorderedCollectionMatchpublic static boolean unorderedCollectionMatch(Collection<QName> a, Collection<QName> b) 
 - 
matchWithUripublic static boolean matchWithUri(QName qname, String uri) Matches QName with a URI representation. The URL may in fact be just the local part.
 - 
resolveNspublic static QName resolveNs(QName a, Collection<QName> col) 
 - 
matchAnypublic static boolean matchAny(QName nameToFind, Collection<? extends QName> names) 
 - 
createCollectionpublic static Collection<QName> createCollection(QName... qnames) 
 - 
isUnqualifiedpublic static boolean isUnqualified(QName name) 
 - 
isQualifiedpublic static boolean isQualified(QName name) 
 - 
isUnqualifiedpublic static boolean isUnqualified(String uri) 
 - 
isTolerateUndeclaredPrefixespublic static boolean isTolerateUndeclaredPrefixes() 
 - 
setTolerateUndeclaredPrefixespublic static void setTolerateUndeclaredPrefixes(boolean value) 
 - 
setTemporarilyTolerateUndeclaredPrefixespublic static void setTemporarilyTolerateUndeclaredPrefixes(Boolean value) 
 - 
reportUndeclaredNamespacePrefixpublic static void reportUndeclaredNamespacePrefix(String prefix, String context) 
 - 
isPrefixUndeclaredpublic static boolean isPrefixUndeclared(String namespacePrefix) 
 - 
isUripublic static boolean isUri(String string) 
 - 
containspublic static boolean contains(Collection<? extends QName> col, QName qname) 
 - 
removepublic static boolean remove(Collection<? extends QName> col, QName qname) 
 
- 
 
-