Package tracopt :: Package perm :: Module config_perm_provider :: Class ExtraPermissionsProvider

Class ExtraPermissionsProvider

source code

         object --+    
                  |    
trac.core.Component --+
                      |
                     ExtraPermissionsProvider

Extra permission provider.

This component provides a way to add arbitrary permissions to a Trac environment. This can be useful for adding new permissions to use for workflow actions, for example.

To add new permissions, create a new section [extra-permissions] in your trac.ini. Every entry in that section defines a meta-permission and a comma-separated list of permissions. For example: {{{ [extra-permissions] extra_admin = extra_view, extra_modify, extra_delete }}} This entry will define three new permissions EXTRA_VIEW, EXTRA_MODIFY and EXTRA_DELETE, as well as a meta-permissions EXTRA_ADMIN that grants all three permissions.

If you don't want a meta-permission, start the meta-name with an underscore (_): {{{ [extra-permissions] _perms = extra_view, extra_modify }}}

Nested Classes

Inherited from trac.core.Component: __metaclass__

Instance Methods
 
get_permission_actions(self) source code
 
__init__(self, compmgr, init=None, cls=<class 'tracopt.perm.config_perm_provider.ExtraPermissionsProv...)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Static Methods

Inherited from trac.core.Component: __new__, implements

Properties

Inherited from object: __class__

Method Details

__init__(self, compmgr, init=None, cls=<class 'tracopt.perm.config_perm_provider.ExtraPermissionsProv...)
(Constructor)

source code 
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
Overrides: object.__init__
(inherited documentation)