Ldap/Attribute.php

Show: PublicProtectedPrivateinherited
Table of Contents
Zend Framework
LICENSE This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.
Category
Zend  
Copyright
Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_Ldap  
Version
$Id$  

\Zend_Ldap_Attribute

Package: Zend_Ldap
Zend_Ldap_Attribute is a collection of LDAP attribute related functions.
Category
Zend  
Copyright
Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  

Constants

>VConstant  PASSWORD_HASH_MD5 = 'md5'
>VConstant  PASSWORD_HASH_SMD5 = 'smd5'
>VConstant  PASSWORD_HASH_SHA = 'sha'
>VConstant  PASSWORD_HASH_SSHA = 'ssha'
>VConstant  PASSWORD_UNICODEPWD = 'unicodePwd'

Methods

methodprivate_valueFromLdap(string $value) : mixed
static

Parameters
NameTypeDescription
$valuestring
Returns
TypeDescription
mixed
methodprivate_valueFromLdapDateTime(string | \DateTime $value) : integer | null
static

Parameters
NameTypeDescription
$valuestring | \DateTime
Returns
TypeDescription
integer | null
methodprivate_valueToLdap(mixed $value) : string | null
static

Parameters
NameTypeDescription
$valuemixed
Returns
TypeDescription
string | null
methodprivate_valueToLdapDateTime(integer $value, boolean $utc) : string | null
static

Parameters
NameTypeDescription
$valueinteger
$utcboolean
Returns
TypeDescription
string | null
methodpublicattributeHasValue(array $data, string $attribName, mixed | array $value) : boolean
static

Checks if the given value(s) exist in the attribute

Parameters
NameTypeDescription
$dataarray
$attribNamestring
$valuemixed | array
Returns
TypeDescription
boolean
methodpublicconvertFromLdapDateTimeValue(string $value) : integer | null
static

Converts LDAP date/time representation into a timestamp

Parameters
NameTypeDescription
$valuestring
Returns
TypeDescription
integer | null- null if the value cannot be converted.
methodpublicconvertFromLdapValue(string $value) : mixed
static

Converts an LDAP value into its PHP data type

Parameters
NameTypeDescription
$valuestring
Returns
TypeDescription
mixed
Details
Deprected
use Zend_Ldap_Converter instead  
methodpublicconvertToLdapDateTimeValue(integer $value, boolean $utc = false) : string | null
static

Converts a timestamp into its LDAP date/time representation

Parameters
NameTypeDescription
$valueinteger
$utcboolean
Returns
TypeDescription
string | null- null if the value cannot be converted.
methodpublicconvertToLdapValue(mixed $value) : string | null
static

Converts a PHP data type into its LDAP representation

Parameters
NameTypeDescription
$valuemixed
Returns
TypeDescription
string | null- null if the PHP data type cannot be converted.
Details
Deprected
use Zend_Ldap_Converter instead  
methodpubliccreatePassword(string $password, string $hashType = self::PASSWORD_HASH_MD5) : string
static

Creates a LDAP password.

Parameters
NameTypeDescription
$passwordstring
$hashTypestring
Returns
TypeDescription
string
methodpublicgetAttribute(array $data, string $attribName, integer $index = null) : array | mixed
static

Gets a LDAP attribute.

Parameters
NameTypeDescription
$dataarray
$attribNamestring
$indexinteger
Returns
TypeDescription
array | mixed
methodpublicgetDateTimeAttribute(array $data, string $attribName, integer $index = null) : array | integer
static

Gets a LDAP date/time attribute.

Parameters
NameTypeDescription
$dataarray
$attribNamestring
$indexinteger
Returns
TypeDescription
array | integer
methodpublicremoveDuplicatesFromAttribute(array $data, string $attribName) : void
static

Removes duplicate values from a LDAP attribute

Parameters
NameTypeDescription
$dataarray
$attribNamestring
methodpublicremoveFromAttribute(array $data, string $attribName, mixed | array $value) : void
static

Remove given values from a LDAP attribute

Parameters
NameTypeDescription
$dataarray
$attribNamestring
$valuemixed | array
methodpublicsetAttribute(array $data, string $attribName, scalar | array | \Traversable $value, boolean $append = false) : void
static

Sets a LDAP attribute.

Parameters
NameTypeDescription
$dataarray
$attribNamestring
$valuescalar | array | \Traversable
$appendboolean
methodpublicsetDateTimeAttribute(array $data, string $attribName, integer | array | \Traversable $value, boolean $utc = false, boolean $append = false) : null
static

Sets a LDAP date/time attribute.

Parameters
NameTypeDescription
$dataarray
$attribNamestring
$valueinteger | array | \Traversable
$utcboolean
$appendboolean
Returns
TypeDescription
null
methodpublicsetPassword(array $data, string $password, string $hashType = self::PASSWORD_HASH_MD5, string | null $attribName = null) : null
static

Sets a LDAP password.

Parameters
NameTypeDescription
$dataarray
$passwordstring
$hashTypestring
$attribNamestring | null
Returns
TypeDescription
null
Documentation was generated by phpDocumentor 2.2.0 .