User trustee.
More...
#include <base/security/User.h>
Inherits Object.
User trustee.
A user trustee.
- Version
- 1.2
- Examples
- testsuite/ls.cpp, and testsuite/Quota.cpp.
◆ User() [1/5]
Initializes user as invalid.
◆ User() [2/5]
User::User |
( |
unsigned long |
_id | ) |
|
Initializes user by id. Raises OutOfDomain if the specified id is not supported by the platform.
◆ User() [3/5]
User::User |
( |
const void * |
id | ) |
|
Initializes user by id. Raises OutOfDomain if the specified id is not supported by the platform.
◆ User() [4/5]
User::User |
( |
const User & |
copy | ) |
|
|
noexcept |
Initializes user from other user.
◆ User() [5/5]
User::User |
( |
const String & |
name | ) |
|
Initializes user by name.
◆ getCurrentUser()
static User User::getCurrentUser |
( |
| ) |
|
|
static |
◆ getFullName()
String User::getFullName |
( |
| ) |
const |
Returns the full name of the account.
◆ getGroups()
Returns the groups to which the user belongs.
◆ getHomeFolder()
String User::getHomeFolder |
( |
| ) |
const |
◆ getId()
const void* User::getId |
( |
| ) |
const |
|
inlinenoexcept |
Returns the id of the user.
◆ getIntegralId()
unsigned long User::getIntegralId |
( |
| ) |
const |
|
inlinenoexcept |
Returns the integral id of the user.
◆ getName()
String User::getName |
( |
bool |
fallback = true | ) |
const |
◆ isAdmin()
bool User::isAdmin |
( |
| ) |
const |
◆ isMemberOf()
bool User::isMemberOf |
( |
const Group & |
group | ) |
|
Returns true if the user is a member of the specified group.
- Returns
- false if the group doesn't exist.
◆ isValid()
bool User::isValid |
( |
| ) |
const |
|
inlinenoexcept |
Returns true if the user is initialized. This does not mean that the user exists.
◆ operator!=()
bool User::operator!= |
( |
const User & |
compare | ) |
const |
|
inlinenoexcept |
Returns false if the users are not identical. The method returns false if both users are invalid.
◆ operator=()
User& User::operator= |
( |
const User & |
assign | ) |
|
|
noexcept |
Assignment of user by user.
◆ operator==()
bool User::operator== |
( |
const User & |
compare | ) |
const |
|
noexcept |
Returns true if the users are identical. The method returns true if both users are invalid.