Perform an xpath query on the given XML document which may be a String, byte array, or InputStream. See xml->doc, and xp:compile.
Perform an xpath query on the given XML document which may be a String, byte array, or InputStream. See xml->doc, and xp:compile.
($x:attrs xp-compiler xp xml & [opts])
Perform an xpath search, resulting in one and only one node. Return only the node's attrs.
Perform an xpath search, resulting in one and only one node. Return only the node's attrs.
($x:attrs* xp-compiler xp xml opts)
($x:attrs* xp-compiler xp xml attr-name opts)
Perform an xpath search, resulting in zero or more nodes. When an attr-name is passed, return only each the node's attrs.
Perform an xpath search, resulting in zero or more nodes. When an attr-name is passed, return only each the node's attrs.
($x:attrs+ xp-compiler xp xml & [opts])
Perform an xpath search, resulting in one or more nodes. Return only each the node's attrs.
Perform an xpath search, resulting in one or more nodes. Return only each the node's attrs.
($x:attrs? xp-compiler xp xml & [opts])
Perform an xpath search, resulting in zero or one node. Return only the node's attrs.
Perform an xpath search, resulting in zero or one node. Return only the node's attrs.
($x:node xp-compiler xp xml & [opts])
Perform an xpath search, resulting in one and only one node. Returns the node.
Perform an xpath search, resulting in one and only one node. Returns the node.
($x:node* xp-compiler xp xml & [opts])
Perform an xpath search, resulting in zero or more nodes. Returns the nodes.
Perform an xpath search, resulting in zero or more nodes. Returns the nodes.
($x:node+ xp-compiler xp xml & [opts])
Perform an xpath search, resulting in one or more nodes. Returns the nodes.
Perform an xpath search, resulting in one or more nodes. Returns the nodes.
($x:node? xp-compiler xp xml & [opts])
Perform an xpath search, resulting in zero or one node. Returns the node.
Perform an xpath search, resulting in zero or one node. Returns the node.
($x:tag xp-compiler xp xml & [opts])
Perform an xpath search, resulting in one and only one node. Return only the tag name.
Perform an xpath search, resulting in one and only one node. Return only the tag name.
($x:tag* xp-compiler xp xml & [opts])
Perform an xpath search, resulting in zero or more nodes, return just the tag name.
Perform an xpath search, resulting in zero or more nodes, return just the tag name.
($x:tag+ xp-compiler xp xml & [opts])
Perform an xpath search, resulting in one or more nodes. Return only the tag name.
Perform an xpath search, resulting in one or more nodes. Return only the tag name.
($x:tag? xp-compiler xp xml & [opts])
Perform an xpath search, resulting in zero or one node. Return only the tag name.
Perform an xpath search, resulting in zero or one node. Return only the tag name.
($x:text xp-compiler xp xml & [opts])
Perform an xpath search, resulting in one and only one node. Return only the node's text.
Perform an xpath search, resulting in one and only one node. Return only the node's text.
($x:text* xp-compiler xp xml & [opts])
Perform an xpath search, resulting in zero or more nodes. Return only each the node's text.
Perform an xpath search, resulting in zero or more nodes. Return only each the node's text.
($x:text+ xp-compiler xp xml & [opts])
Perform an xpath search, resulting in one or more nodes. Return only each the node's text.
Perform an xpath search, resulting in one or more nodes. Return only each the node's text.
($x:text? xp-compiler xp xml & [opts])
Perform an xpath search, resulting in zero or one node. Return only the node's text.
Perform an xpath search, resulting in zero or one node. Return only the node's text.
(abs-path node)
Determine an absolute xpath expression that locates this node inside the enclosing document. Based on code developed by Florian Bösch on XML-SIG (http://mail.python.org/pipermail/xml-sig/2004-August/010423.html) as enhanced and published by Uche Ogbuji (http://www.xml.com/pub/a/2004/11/24/py-xml.html)
Determine an absolute xpath expression that locates this node inside the enclosing document. Based on code developed by Florian Bösch on XML-SIG (http://mail.python.org/pipermail/xml-sig/2004-August/010423.html) as enhanced and published by Uche Ogbuji (http://www.xml.com/pub/a/2004/11/24/py-xml.html)
Determine the absolute path to node.
Determine the absolute path to node.
(attrs nodeattrs)
Extract the attributes from the node.
Extract the attributes from the node.
(dom-node-list->seq node-list)
Convert a org.w3c.dom.NodeList into a clojure sequence.
Convert a org.w3c.dom.NodeList into a clojure sequence.
(dom-node-map->seq node-list)
Convert a org.w3c.dom.NodeList into a clojure sequence.
Convert a org.w3c.dom.NodeList into a clojure sequence.
Helper for generating XML (mostly used by the test suite).
Helper for generating XML (mostly used by the test suite).
(format-tag-seq tag-and-attrs & [with-attrs])
Helper for generating XML (mostly used by the test suite).
Helper for generating XML (mostly used by the test suite).
(input-stream->dom istr & [opts])
Convert an input stream into a DOM.
Convert an input stream into a DOM.
(make-xpath-compiler _opts)
Inputs: [_opts :- Options]
Inputs: [_opts :- Options]
(node->map node)
Create a logical map out of the Node's properties: :node the-node :tag tag name of node :attrs map of the node's attributes :text the text of the node :children a lazy sequence of the node's children.
Create a logical map out of the Node's properties: :node the-node :tag tag name of node :attrs map of the node's attributes :text the text of the node :children a lazy sequence of the node's children.
(node->xml node)
Convert a Node to a String of XML.
Convert a Node to a String of XML.
(node-list->seq thing)
Convert a org.w3c.dom.NodeList into a clojure sequence.
Convert a org.w3c.dom.NodeList into a clojure sequence.
(node-name node)
Accessor for the node's name.
Accessor for the node's name.
(nscontext prefix-map)
Create a javax.xml.namespace.NamespaceContext from the given map.
Create a javax.xml.namespace.NamespaceContext from the given map.
(summarize s len)
Summarize a string to a specific maximu length (truncating it and adding ... if it is longer than len).
Summarize a string to a specific maximu length (truncating it and adding ... if it is longer than len).
(tag tag & body)
Helper for generating XML (mostly used by the test suite).
Helper for generating XML (mostly used by the test suite).
(text node)
Accessor for text content from the node.
Accessor for text content from the node.
Convert various forms of XML into a Document. Supported forms:
String byte array Input Stream org.w3c.dom.Document org.w3c.dom.Node
Convert various forms of XML into a Document. Supported forms: String byte array Input Stream org.w3c.dom.Document org.w3c.dom.Node
(xml-bytes->dom bytes & [opts])
Convert a byte array into a DOM.
Convert a byte array into a DOM.
(xmlnsmap-from-document xml)
Extract a map of XML Namespace prefix to URI (and URI to prefix) recursively from the entire document.
Extract a map of XML Namespace prefix to URI (and URI to prefix) recursively from the entire document.
(xmlnsmap-from-node node)
Extract a map of XML Namespace prefix to URI (and URI to prefix) from the given node.
Extract a map of XML Namespace prefix to URI (and URI to prefix) from the given node.
(xmlnsmap-from-root-node xp-compiler xml & [opts])
Extract a map of XML Namespace prefix to URI (and URI to prefix) from the root node of the document.
Extract a map of XML Namespace prefix to URI (and URI to prefix) from the root node of the document.
Compile an XPath expression. If the argument is already a compiled XPath expression, it is returned as-is.
Compile an XPath expression. If the argument is already a compiled XPath expression, it is returned as-is.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close