Class rex_complex_perm

Abstract class for complex permissions.

All permission check methods ("hasPerm()" etc.) in child classes should return "true" for admins

Direct known subclasses

rex_clang_perm, rex_media_perm, rex_module_perm, rex_structure_perm

Abstract
Package: redaxo\core\login
Author: gharlan
Located at redaxo/src/core/lib/login/complex_perm.php

Methods summary

protected
# __construct( rex_user $user, mixed $perms )

Constructor.

public boolean
# hasAll( )

Returns if the user has the permission for all items.

public static array
# getFieldParams( )

Returns the field params for the role form.

public static
# register( string $key, string $class )

Registers a new complex perm class.

public static array
# getAll( )

Returns all complex perm classes.

public static self
# get( rex_user $user, string $key, mixed $perms = [] )

Returns the complex perm.

public static
# removeItem( string $key, string $item )

Should be called if an item is removed.

public static
# replaceItem( string $key, string $item, string $new )

Should be called if an item is replaced.

Constants summary

string ALL
#'all'

Properties summary

protected rex_user $user

User instance.

protected array $perms

Array of permissions.

#[]