https://github.com/pharo-contributions/XML-XPath
An XPath library for Pharo
https://github.com/pharo-contributions/XML-XPath
Last synced: 6 months ago
JSON representation
An XPath library for Pharo
- Host: GitHub
- URL: https://github.com/pharo-contributions/XML-XPath
- Owner: pharo-contributions
- License: mit
- Created: 2019-11-04T21:15:22.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2024-08-04T03:34:03.000Z (9 months ago)
- Last Synced: 2024-11-14T11:15:04.070Z (6 months ago)
- Language: Smalltalk
- Size: 2.88 MB
- Stars: 5
- Watchers: 6
- Forks: 8
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-pharo - XML-XPath - Official XPath library for Pharo. (Data interexchange format)
README
# XML-XPath
[](https://travis-ci.org/pharo-contributions/XML-XPath) [](https://coveralls.io/github/pharo-contributions/XML-XPath?branch=master)
[](https://github.com/pharo-contributions/XML-XPath/actions?query=workflow%3ABuild)
[](https://codecov.io/gh/pharo-contributions/XML-XPath/branch/master)[](https://pharo.org/download)
[](https://pharo.org/download)
[](https://pharo.org/download)
[](https://pharo.org/download)
[](https://pharo.org/download)
[](https://pharo.org/download)
[](https://pharo.org/download)An XPath library for [Pharo](http://www.pharo.org) leveraging the XML parsing capabilities of [XMLParser](https://github.com/pharo-contributions/XML-XMLParser). Supports XPath 1.0 syntax with extensions.
## Installation
```Smalltalk
Metacello new
baseline: 'XPath';
repository: 'github://pharo-contributions/XML-XPath/src';
load.
```## Usage
A simple example on how to use the XPath class:
```Smalltalk
doc := XMLDOMParser parse: aStream.
path := XPath for: 'entry/content/@src'.
urls := path in: doc.
```This will look for each 'src' attribute of each 'content' node of all 'entry' nodes in the document.
## LICENSE
[MIT License](LICENSE)## History
This project was migrated from [http://smalltalkhub.com/#!/~PharoExtras/XPath](http://smalltalkhub.com/#!/~PharoExtras/XPath)