Package Home

Zend Framework 2 Documentation (Manual)

PHK Home

File: /modules/zend.ldap.api.ldap.filter.html

Size:11418
Storage flags:no_autoload,compress/gzip (30%)

Zend\Ldap\Filter — Zend Framework 2 2.4.2 documentation

Zend\Ldap\FilterΒΆ

Zend\Ldap\Filter API
Method Description
Zend\Ldap\Filter equals(string $attr, string $value) Creates an ‘equals’ filter: (attr=value).
Zend\Ldap\Filter begins(string $attr, string $value) Creates an ‘begins with’ filter: (attr=value*).
Zend\Ldap\Filter ends(string $attr, string $value) Creates an ‘ends with’ filter: (attr=*value).
Zend\Ldap\Filter contains(string $attr, string $value) Creates an ‘contains’ filter: (attr=*value*).
Zend\Ldap\Filter greater(string $attr, string $value) Creates an ‘greater’ filter: (attr>value).
Zend\Ldap\Filter greaterOrEqual(string $attr, string $value) Creates an ‘greater or equal’ filter: (attr>=value).
Zend\Ldap\Filter less(string $attr, string $value) Creates an ‘less’ filter: (attr<value).
Zend\Ldap\Filter lessOrEqual(string $attr, string $value) Creates an ‘less or equal’ filter: (attr<=value).
Zend\Ldap\Filter approx(string $attr, string $value) Creates an ‘approx’ filter: (attr~=value).
Zend\Ldap\Filter any(string $attr) Creates an ‘any’ filter: (attr=*).
Zend\Ldap\Filter string(string $filter) Creates a simple custom string filter. The user is responsible for all value-escaping as the filter is used as is.
Zend\Ldap\Filter mask(string $mask, string $value,...) Creates a filter from a string mask. All $value parameters will be escaped and substituted into $mask by using sprintf()
Zend\Ldap\Filter andFilter(Zend\Ldap\Filter\AbstractFilter $filter,...) Creates an ‘and’ filter from all arguments given.
Zend\Ldap\Filter orFilter(Zend\Ldap\Filter\AbstractFilter $filter,...) Creates an ‘or’ filter from all arguments given.
__construct(string $attr, string $value, string $filtertype, string|null $prepend, string|null $append) Constructor. Creates an arbitrary filter according to the parameters supplied. The resulting filter will be a concatenation $attr . $filtertype . $prepend . $value . $append. Normally this constructor is not needed as all filters can be created by using the appropriate factory methods.
string toString() Returns a string representation of the filter.
string __toString() Returns a string representation of the filter. Proxies to Zend\Ldap\Filter::toString().
Zend\Ldap\Filter\AbstractFilter negate() Negates the current filter.
Zend\Ldap\Filter\AbstractFilter addAnd(Zend\Ldap\Filter\AbstractFilter $filter,...) Creates an ‘and’ filter from the current filter and all filters passed in as the arguments.
Zend\Ldap\Filter\AbstractFilter addOr(Zend\Ldap\Filter\AbstractFilter $filter,...) Creates an ‘or’ filter from the current filter and all filters passed in as the arguments.
string|array escapeValue(string|array $values) Escapes the given $values according to RFC 2254 so that they can be safely used in LDAP filters. If a single string is given, a string is returned - otherwise an array is returned. Any control characters with an ASCII code < 32 as well as the characters with special meaning in LDAP filters “*”, “(”, ”)”, and “\” (the backslash) are converted into the representation of a backslash followed by two hex digits representing the hexadecimal value of the character.
string|array unescapeValue(string|array $values) Undoes the conversion done by Zend\Ldap\Filter::escapeValue(). Converts any sequences of a backslash followed by two hex digits into the corresponding character.

This Page

Note: You need to stay logged into your GitHub account to contribute to the documentation.

Edit this document

Edit this document

The source code of this file is hosted on GitHub. Everyone can update and fix errors in this document with few clicks - no downloads needed.

  1. Login with your GitHub account.
  2. Go to Zend\Ldap\Filter on GitHub.
  3. Edit file contents using GitHub's text editor in your web browser
  4. Fill in the Commit message text box at the end of the page telling why you did the changes. Press Propose file change button next to it when done.
  5. On Send a pull request page you don't need to fill in text anymore. Just press Send pull request button.
  6. Your changes are now queued for review under project's Pull requests tab on GitHub.

For more information about the PHK package format: http://phk.tekwire.net