net.sf.saxon.s9api.QName Java Examples
The following examples show how to use
net.sf.saxon.s9api.QName.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: TECore.java From teamengine with Apache License 2.0 | 6 votes |
String getAssertionValue(String text, XdmNode paramsVar) { if (text.indexOf("$") < 0) { return text; } String newText = text; XdmNode params = (XdmNode) paramsVar.axisIterator(Axis.CHILD).next(); XdmSequenceIterator it = params.axisIterator(Axis.CHILD); while (it.hasNext()) { XdmNode n = (XdmNode) it.next(); QName qname = n.getNodeName(); if (qname != null) { String tagname = qname.getLocalName(); if (tagname.equals("param")) { String name = n.getAttributeValue(LOCALNAME_QNAME); String label = getLabel(n); newText = StringUtils.replaceAll(newText, "{$" + name + "}", label); } } } newText = StringUtils.replaceAll(newText, "{$context}", contextLabel); return newText; }
Example #2
Source File: SaxonRunnerApp.java From intellij-xquery with Apache License 2.0 | 5 votes |
private QName getName(String name, String namespace) { if (namespace != null) { return new QName(namespace, name); } else { return new QName(name); } }
Example #3
Source File: ConfigurationLoader.java From validator with Apache License 2.0 | 4 votes |
private static boolean isSupportedDocument(final XdmNode doc) { final XdmNode root = findRoot(doc); final String frameworkVersion = root.getAttributeValue(new QName("frameworkVersion")); return startsWith(frameworkVersion, SUPPORTED_MAJOR_VERSION) && root.getNodeName().getNamespaceURI().equals(SUPPORTED_MAJOR_VERSION_SCHEMA); }
Example #4
Source File: MyConcatExtensionFunction.java From kite with Apache License 2.0 | 4 votes |
@Override public QName getName() { return new QName("my.custom.uri", "my-concat"); }
Example #5
Source File: XQueryProcessor.java From spark-xml-utils with Apache License 2.0 | 2 votes |
/** * Set the external variable. The value should be a String. * * @param name Name of the external variable in the XQuery * @param value Value for the external variable */ public void setExternalVariable(String name, String value) { eval.setExternalVariable(new QName(name), new XdmAtomicValue(value)); }