LdapRepository: Add method isAmbiguous()

refs #9950
This commit is contained in:
Johannes Meyer 2015-09-28 10:56:15 +02:00
parent e1aab183e3
commit d7655972ed
1 changed files with 23 additions and 1 deletions

View File

@ -42,6 +42,15 @@ abstract class LdapRepository extends Repository
'groupofuniquenames' => 'groupOfUniqueNames'
);
/**
* Object attributes whose value is not distinguished name
*
* @var array
*/
protected $ambiguousAttributes = array(
'posixGroup' => 'memberUid'
);
/**
* Create a new LDAP repository object
*
@ -68,4 +77,17 @@ abstract class LdapRepository extends Repository
return $name;
}
}
/**
* Return whether the given object attribute's value is not a distinguished name
*
* @param string $objectClass
* @param string $attributeName
*
* @return bool
*/
protected function isAmbiguous($objectClass, $attributeName)
{
return isset($this->ambiguousAttributes[$objectClass][$attributeName]);
}
}