NAME

AccessUser - access user component


DESCRIPTION

This component type implements the meaning of a user in the access control mechanism. Every user may be a member of several groups and every group may contain several users.

The properties of AccessUser are: inherited real name, login name, like ``joe'', password, default_group virtual component, default_owner_perms, default_group_perms, default_other_perms, all 3 of type AccessPermissions, and r_AccessGroup_users reversed component collection of AccessGroup components.


REQUIREMENTS

the Podius::Component::Publishable manpage, the Podius::Property::Scalar manpage, the Podius::Property::Password manpage, the Podius::Property::VComponent manpage, the Podius::Property::AccessPermissions manpage, the Podius::Property::RComponentCollection manpage.


METHODS

set_data

description
Sets component properties.

parameters
All parameters are optional,
  * name - a real name of the user ("Joe Smith")
  * login - a unique login name of the user ("joe")
  * password - string
  * default_group - AccessGroup component
  * default_owner_perms - AccessPermissions
  * default_group_perms - AccessPermissions
  * default_other_perms - AccessPermissions

returns
None.

is_superuser

description
Checks whether the user is superuser.

parameters
None.

returns
1 if superuser, 0 otherwise.

is_in_group

description
Checks whether the user is in the given group.

parameters
  * component AccessGroup to check against
returns
1 if in group, 0 otherwise.