From 7178026b8bdf06700a6fecb06f0953a2a6dd9616 Mon Sep 17 00:00:00 2001 From: Johannes Meyer Date: Mon, 4 May 2015 11:15:20 +0200 Subject: [PATCH] Ldap\Connection: Implement interface Selectable refs #8826 --- library/Icinga/Protocol/Ldap/Connection.php | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/library/Icinga/Protocol/Ldap/Connection.php b/library/Icinga/Protocol/Ldap/Connection.php index 829545bd8..de7d7b628 100644 --- a/library/Icinga/Protocol/Ldap/Connection.php +++ b/library/Icinga/Protocol/Ldap/Connection.php @@ -3,12 +3,13 @@ namespace Icinga\Protocol\Ldap; -use Icinga\Exception\ProgrammingError; -use Icinga\Protocol\Ldap\Exception as LdapException; -use Icinga\Application\Platform; use Icinga\Application\Config; use Icinga\Application\Logger; +use Icinga\Application\Platform; use Icinga\Data\ConfigObject; +use Icinga\Data\Selectable; +use Icinga\Exception\ProgrammingError; +use Icinga\Protocol\Ldap\Exception as LdapException; /** * Backend class managing all the LDAP stuff for you. @@ -24,7 +25,7 @@ use Icinga\Data\ConfigObject; * )); * */ -class Connection +class Connection implements Selectable { const LDAP_NO_SUCH_OBJECT = 32; const LDAP_SIZELIMIT_EXCEEDED = 4; @@ -122,6 +123,11 @@ class Connection return $this->root; } + /** + * Provide a query on this connection + * + * @return Query + */ public function select() { return new Query($this);