Adldap\Models\Traits\HasMemberOfTrait::getGroupNames PHP Метод

getGroupNames() публичный Метод

If a recursive option is given, groups of groups are retrieved and then merged with the resulting collection.
public getGroupNames ( boolean $recursive = false ) : array
$recursive boolean
Результат array
    public function getGroupNames($recursive = false)
    {
        $names = $this->getGroups([], $recursive)->map(function (Group $group) {
            return $group->getCommonName();
        })->toArray();
        return array_unique($names);
    }