Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/libgraviton/php-rql-parser
A PHP RQL Parsing Library
https://github.com/libgraviton/php-rql-parser
Last synced: 2 months ago
JSON representation
A PHP RQL Parsing Library
- Host: GitHub
- URL: https://github.com/libgraviton/php-rql-parser
- Owner: libgraviton
- Created: 2014-11-11T07:55:49.000Z (about 10 years ago)
- Default Branch: develop
- Last Pushed: 2023-03-13T13:00:40.000Z (almost 2 years ago)
- Last Synced: 2024-04-24T14:37:44.236Z (9 months ago)
- Language: PHP
- Size: 420 KB
- Stars: 14
- Watchers: 24
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
php-rql-parser - Query MongoDB using RQL in PHP
==============This is a wrapper around [libgraviton/rql-parser](https://github.com/libgraviton/rql-parser) that combines that parser with a small layer of mongodb integration.
This package adheres to [SemVer](http://semver.org/spec/v2.0.0.html) versioning.
It uses a github version of [git-flow](http://nvie.com/posts/a-successful-git-branching-model/) in which new features and bugfixes must be merged to develop
using a github pull request. It uses the standard git-flow naming conventions with the addition of a 'v' prefix to version tags.## Installation
Install it using [composer](https://getcomposer.org/).
```bash
composer require graviton/php-rql-parser
```## Usage
```php
setBuilder($builder);
$lexer = new \Graviton\RqlParser\Lexer;
$parser = \Graviton\RqlParser\Parser::createDefault();// parse some Resource Query Language
$rqlQuery = $parser->parse($lexer->tokenize($rql));// get query
$query = $visitor->visit($rqlQuery)->getQuery();// ...
```## Development
We welcome contributions on the develop branch.