arangodb / arangodb-php

PHP ODM for ArangoDB
https://www.arangodb.com
Apache License 2.0
183 stars 43 forks source link

Added ability to pass an instance of Graph for GraphHandler methods #168

Closed olivermack closed 10 years ago

olivermack commented 10 years ago

Hi,

I stumbled upon this while playing around with the lib... intentionally I expected to be able to work with objects/instances instead of passing graph names to those helper methods.

After merging my changes I saw some more places where I typically like to be able to use an already instantiated object, e.g. https://github.com/triAGENS/ArangoDB-PHP/blob/devel/lib/triagens/ArangoDb/CollectionHandler.php#L261 and following... basically every *Handler class contains some parts where the identifying argument is hardcoded to an id or string.

Does anyone agree? If so I'd like to contribute some more stuff on that - just let me know.

Cheers!

frankmayer commented 10 years ago

Hi there and thanks for your work and input.

Yes, I like the idea to be able to pass objects. I have been experimenting myself with providing a new basic core driver, which is based on even more dependency injection (https://github.com/frankmayer/ArangoDB-PHP-Core). Will be updating that one in April to provide a more bit more docu and a first stable release.

I like this PR and proposed secondary changes. Jan?

olivermack commented 10 years ago

Sorry... I'll clean up the devel and send in new pull requests with published feature branches separately. When I'm ready I'll reference those pull requests here to let you know when you can delete this PR.

olivermack commented 10 years ago

This PR can be closed as i separated it into #169 and #170 .