WhitePagesLdapConnection
in package
LDAP connection for white pages.
Table of Contents
- $profile : WhitePagesProfile
- $server : Connection|null
- __construct() : mixed
- Constructor
- __sleep() : array<string|int, mixed>
- Closes connection to the LDAP server before serialization.
- bind() : bool
- Binds with the given credentials.
- getServer() : Connection|null
- Returns the LDAP handle.
- openLdapConnection() : Connection|null
- Opens the LDAP connection and returns the handle. No bind is done.
Properties
$profile
private
WhitePagesProfile
$profile
$server
private
Connection|null
$server
= null
Methods
__construct()
Constructor
public
__construct(WhitePagesProfile $profile) : mixed
Parameters
- $profile : WhitePagesProfile
-
profile
Return values
mixed —__sleep()
Closes connection to the LDAP server before serialization.
public
__sleep() : array<string|int, mixed>
Return values
array<string|int, mixed> —bind()
Binds with the given credentials.
public
bind(string $userDn, string $password) : bool
Parameters
- $userDn : string
-
user DN
- $password : string
-
password
Return values
bool —bind was successful
getServer()
Returns the LDAP handle.
public
getServer() : Connection|null
Return values
Connection|null —LDAP handle
openLdapConnection()
Opens the LDAP connection and returns the handle. No bind is done.
private
openLdapConnection(WhitePagesProfile $profile) : Connection|null
Parameters
- $profile : WhitePagesProfile
-
profile
Return values
Connection|null —LDAP handle or null if the connection failed