Koine Query Registry
Simple query Registry for storing queries (and params) for logging/debbuging/late executing, (*1)
Code information:, (*2)
, (*3)
Package information:, (*4)
, (*5)
Usage
$registry = new \Koine\QueryRegistry;
$registry->register("SELECT foo FROM bar");
$registry->register("SELECT foo FROM bar WHERE baz=:baz", array(
'baz' => 'somevalue'
));
$registry->getQueries()->last()->dump();
// or
foreach ($registry->getQueries() as $query) {
$db->execute($query->getSql(), $query->getParams());
}
Installing
Via Composer
Append the lib to your requirements key in your composer.json., (*6)
{
// composer.json
// [..]
require: {
// append this line to your requirements
"koine/query-registry": "dev-master"
}
}
Alternative install
Issues/Features proposals
Here is the issue tracker., (*7)
Contributing
Only TDD code will be accepted. Please follow the PSR-2 code standard., (*8)
- Fork it
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Add some feature')
- Push to the branch (
git push origin my-new-feature)
- Create new Pull Request
How to run the tests:
phpunit --configuration tests/phpunit.xml
To check the code standard run:
phpcs --standard=PSR2 lib
phpcs --standard=PSR2 tests
Lincense
MIT, (*9)
Authors