IProfileManager
in
Tags
Table of Contents
Constants
- DEFAULT_PROPERTY_VISIBILITY = [\OCP\Accounts\IAccountManager::PROPERTY_ADDRESS => self::VISIBILITY_SHOW_USERS_ONLY, \OCP\Accounts\IAccountManager::PROPERTY_AVATAR => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_BIOGRAPHY => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_DISPLAYNAME => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_HEADLINE => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_ORGANISATION => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_ROLE => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_EMAIL => self::VISIBILITY_SHOW_USERS_ONLY, \OCP\Accounts\IAccountManager::PROPERTY_PHONE => self::VISIBILITY_SHOW_USERS_ONLY, \OCP\Accounts\IAccountManager::PROPERTY_TWITTER => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_WEBSITE => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_PRONOUNS => self::VISIBILITY_SHOW]
- Default account property visibility
- DEFAULT_VISIBILITY = self::VISIBILITY_SHOW_USERS_ONLY
- Default visibility
- VISIBILITY_HIDE = 'hide'
- Visible to nobody
- VISIBILITY_SHOW = 'show'
- Visible to users, guests, and public access
- VISIBILITY_SHOW_USERS_ONLY = 'show_users_only'
- Visible to users and guests
Methods
- getProfileFields() : array<string|int, mixed>
- Return the profile parameters of the target user that are visible to the visiting user in an associative array
- isProfileEnabled() : bool
- If no user is passed as an argument return whether profile is enabled globally in `config.php`
- isProfileFieldVisible() : bool
- Return whether the profile parameter of the target user is visible to the visiting user
Constants
DEFAULT_PROPERTY_VISIBILITY
Default account property visibility
public
mixed
DEFAULT_PROPERTY_VISIBILITY
= [\OCP\Accounts\IAccountManager::PROPERTY_ADDRESS => self::VISIBILITY_SHOW_USERS_ONLY, \OCP\Accounts\IAccountManager::PROPERTY_AVATAR => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_BIOGRAPHY => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_DISPLAYNAME => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_HEADLINE => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_ORGANISATION => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_ROLE => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_EMAIL => self::VISIBILITY_SHOW_USERS_ONLY, \OCP\Accounts\IAccountManager::PROPERTY_PHONE => self::VISIBILITY_SHOW_USERS_ONLY, \OCP\Accounts\IAccountManager::PROPERTY_TWITTER => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_WEBSITE => self::VISIBILITY_SHOW, \OCP\Accounts\IAccountManager::PROPERTY_PRONOUNS => self::VISIBILITY_SHOW]
Tags
DEFAULT_VISIBILITY
Default visibility
public
mixed
DEFAULT_VISIBILITY
= self::VISIBILITY_SHOW_USERS_ONLY
Tags
VISIBILITY_HIDE
Visible to nobody
public
mixed
VISIBILITY_HIDE
= 'hide'
Tags
VISIBILITY_SHOW
Visible to users, guests, and public access
public
mixed
VISIBILITY_SHOW
= 'show'
Tags
VISIBILITY_SHOW_USERS_ONLY
Visible to users and guests
public
mixed
VISIBILITY_SHOW_USERS_ONLY
= 'show_users_only'
Tags
Methods
getProfileFields()
Return the profile parameters of the target user that are visible to the visiting user in an associative array
public
getProfileFields(IUser $targetUser, IUser|null $visitingUser) : array<string|int, mixed>
Parameters
Tags
Return values
array<string|int, mixed>isProfileEnabled()
If no user is passed as an argument return whether profile is enabled globally in `config.php`
public
isProfileEnabled([IUser|null $user = null ]) : bool
Parameters
- $user : IUser|null = null
Tags
Return values
boolisProfileFieldVisible()
Return whether the profile parameter of the target user is visible to the visiting user
public
isProfileFieldVisible(string $profileField, IUser $targetUser, IUser|null $visitingUser) : bool