Registry / serialization / xmlpath-v2

xmlpath-v2

JSON →
library2.0.0-20150820204837-860cbeca3ebcgogounverified

A Go implementation of a strict subset of XPath for XML document querying.

go get gopkg.in/xmlpath.v2
INSTALL
IMPORT
SIG · XMLPATH-V2
X
xmlpath-v2
serializationgov2.0.0-20150820204837-860cbeca3ebc
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

xmlpath
✓ gopkg.in/xmlpath.v2

Compiles an XPath expression and extracts a string value from XML.

import "gopkg.in/xmlpath.v2" func main() { path, _ := xmlpath.Compile("/root/element") root, _ := xmlpath.Parse(strings.NewReader("<root><element>value</element></root>")) if value, ok := path.String(root); ok { println(value) } }
Debug
Known issues
gotchaOnly supports a strict subset of XPath; complex expressions may fail.
fix
Refer to documentation for supported features.
affects: all
Upgrade
Version history
2.0.0-20150820204837-860cbeca3ebclatest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
20 hits · last 30 days
node
18
OpenAI (training)
1
Resources
xmlpath-v2 — go get xmlpath-v2 · libregistry