You are here

public static function SimpleLdap::ldap_control_paged_result_response in Simple LDAP 7.2

Same name and namespace in other branches
  1. 7 SimpleLdap.class.php \SimpleLdap::ldap_control_paged_result_response()

Wrapper function for ldap_control_paged_result_response().

@throw SimpleLdapException

Parameters

resource $link: An LDAP link identifier.

resouce $result: An LDAP search result identifier.

string $cookie: An opaque structure sent by the server.

int $estimated: The estimated number of entries to retrieve.

Return value

boolean TRUE on success.

1 call to SimpleLdap::ldap_control_paged_result_response()
SimpleLdapServer::search in ./SimpleLdapServer.class.php
Search the LDAP server.

File

./SimpleLdap.class.php, line 565
Class defining base Simple LDAP functionallity.

Class

SimpleLdap
Simple LDAP class.

Code

public static function ldap_control_paged_result_response($link, $result, &$cookie = NULL, &$estimated = NULL) {

  // Devel debugging.
  if (variable_get('simple_ldap_devel', FALSE)) {
    dpm(__FUNCTION__);
    dpm(array(
      '$result' => $result,
      '$cookie' => $cookie,
      '$estimated' => $estimated,
    ));
  }

  // Wrapped function call.
  $return = @ldap_control_paged_result_response($link, $result, $cookie, $estimated);

  // Debugging.
  if (variable_get('simple_ldap_debug', FALSE)) {
    $message = __FUNCTION__ . '($link = @link, $result = @result, $cookie = @cookie, $estimated = @estimated) returns @return';
    $variables = array(
      '@link' => print_r($link, TRUE),
      '@result' => print_r($result, TRUE),
      '@cookie' => print_r($cookie, TRUE),
      '@estimated' => print_r($estimated, TRUE),
      '@return' => print_r($return, TRUE),
    );
    watchdog('simple_ldap', $message, $variables, WATCHDOG_DEBUG);
  }
  return $return;
}