PHP 클래스 LdapTools\Resolver\AttributeNameResolver

저자: Chad Sikorra ([email protected])
파일 보기 프로젝트 열기: ldaptools/ldaptools

보호된 프로퍼티들

프로퍼티 타입 설명
$schema LdapTools\Schema\LdapObjectSchema | null
$selectedAttributes The attribute names in the exact form they were selected for.

공개 메소드들

메소드 설명
__construct ( LdapObjectSchema $schema = null )
fromLdap ( array $entry, array $selectedAttributes ) : array Transform the LDAP attribute names into what is expected given the current context (schema or not).
toLdap ( array $entry ) : array Convert values to LDAP.

보호된 메소드들

메소드 설명
addDnFromLdapIfNotPresent ( array $newEntry, array $entry ) : array The DN attribute is returned by PHP on all LDAP search operations, regardless of selected attributes, and is used in many functions. So add it to the results even if it wasn't selected for.
getSelectedAttributes ( array $selected, array $entry ) : array Determine what attributes should be selected. This accounts for a query wanting all attributes.
selectedButNotPartOfEntry ( string $attribute, array $entry ) : boolean Check whether the attribute name was selected to be returned but is not yet part of the entry. Adjusts the check to be case insensitive.
setMappedNames ( array $newEntry, string $attribute, array | string $value ) : mixed Set all the names mapped to a single attribute from LDAP. This helps account for multiple mappings used for different purposes.

메소드 상세

__construct() 공개 메소드

public __construct ( LdapObjectSchema $schema = null )
$schema LdapTools\Schema\LdapObjectSchema

addDnFromLdapIfNotPresent() 보호된 메소드

The DN attribute is returned by PHP on all LDAP search operations, regardless of selected attributes, and is used in many functions. So add it to the results even if it wasn't selected for.
protected addDnFromLdapIfNotPresent ( array $newEntry, array $entry ) : array
$newEntry array
$entry array
리턴 array

fromLdap() 공개 메소드

Transform the LDAP attribute names into what is expected given the current context (schema or not).
public fromLdap ( array $entry, array $selectedAttributes ) : array
$entry array The LDAP entry.
$selectedAttributes array The attributes that were selected.
리턴 array

getSelectedAttributes() 보호된 메소드

Determine what attributes should be selected. This accounts for a query wanting all attributes.
protected getSelectedAttributes ( array $selected, array $entry ) : array
$selected array
$entry array
리턴 array

selectedButNotPartOfEntry() 보호된 메소드

Check whether the attribute name was selected to be returned but is not yet part of the entry. Adjusts the check to be case insensitive.
protected selectedButNotPartOfEntry ( string $attribute, array $entry ) : boolean
$attribute string
$entry array
리턴 boolean

setMappedNames() 보호된 메소드

Set all the names mapped to a single attribute from LDAP. This helps account for multiple mappings used for different purposes.
protected setMappedNames ( array $newEntry, string $attribute, array | string $value ) : mixed
$newEntry array
$attribute string
$value array | string
리턴 mixed

toLdap() 공개 메소드

Convert values to LDAP.
public toLdap ( array $entry ) : array
$entry array The LDAP entry.
리턴 array

프로퍼티 상세

$schema 보호되어 있는 프로퍼티

protected LdapObjectSchema,LdapTools\Schema|null $schema
리턴 LdapTools\Schema\LdapObjectSchema | null

$selectedAttributes 보호되어 있는 프로퍼티

The attribute names in the exact form they were selected for.
protected $selectedAttributes