User
    
            
            in package
            
        
    
            
            implements
                            UserContract                    
    
            
            Uses
                            UserLocationTrait                    
    
Tags
Table of Contents
Interfaces
- UserContract
 - Interface UserContract.
 
Constants
- AUTO_APPROVED_TAGGED_SETTING = 'user_auto_add_tagger_post'
 - Profile/Account setting name.
 - AUTO_APPROVED_TAGGER_POST = 0
 - AUTO_PLAY_VIDEO_SETTING = 'user_auto_play_videos'
 - DATE_OF_BIRTH_SHOW_ALL = 4
 - DATE_OF_BIRTH_SHOW_DAY_MONTH = 2
 - DISPLAY_BOTH = 'both'
 - DISPLAY_FULL_NAME = 'full_name'
 - DISPLAY_USER_NAME = 'user_name'
 - GENERATED_USER_NAME = 'user-%s-%s'
 - MENTION_REGEX = '^\\[user=(.*?)\\]^'
 - NOT_AUTO_APPROVED_TAGGER_POST = 1
 - THEME_ID_SETTING = 'profile_theme_id'
 - THEME_PREFERENCE_NAMES = [self::THEME_TYPE_SETTING, self::THEME_ID_SETTING]
 - THEME_TYPE_SETTING = 'profile_theme_type'
 
Properties
Methods
- __construct() : mixed
 - canViewLocation() : bool
 - getAddress() : string|null
 - getFirstName() : string
 - getFriendship() : int|null
 - getGender() : string|null
 - getGuestUser() : Authenticatable
 - getLastName() : string
 - getLocation() : array<string, mixed>
 - getLocationValue() : string
 - getMentions() : array<string|int, int>
 - getNotificationSettingsByChannel() : array<int, mixed>
 - getPossessiveGender() : string
 - getShortName() : string
 - getSummary() : string|null
 - getTimeZoneForForm() : array<int, mixed>
 - getTimeZoneNameById() : string|null
 - getUserAge() : int|null
 - getUsersByRoleId() : Collection|null
 - getVideoSettings() : array<string, mixed>
 - hasPendingSubscription() : array<string|int, mixed>|null
 - isBan() : bool
 - isFollowing() : bool
 - splitName() : array<string|int, mixed>
 - totalFollowers() : int
 - updateInvisibleMode() : User
 - updateLastActivity() : bool
 - updateLastLogin() : bool
 - updateNotificationSettingsByChannel() : bool
 
Constants
AUTO_APPROVED_TAGGED_SETTING
Profile/Account setting name.
    public
        mixed
    AUTO_APPROVED_TAGGED_SETTING
    = 'user_auto_add_tagger_post'
    
    
    
AUTO_APPROVED_TAGGER_POST
    public
        mixed
    AUTO_APPROVED_TAGGER_POST
    = 0
    
    
    
AUTO_PLAY_VIDEO_SETTING
    public
        mixed
    AUTO_PLAY_VIDEO_SETTING
    = 'user_auto_play_videos'
    
    
    
DATE_OF_BIRTH_SHOW_ALL
    public
        mixed
    DATE_OF_BIRTH_SHOW_ALL
    = 4
    
    
    
    Tags
DATE_OF_BIRTH_SHOW_DAY_MONTH
    public
        mixed
    DATE_OF_BIRTH_SHOW_DAY_MONTH
    = 2
    
    
    
    Tags
DISPLAY_BOTH
    public
        mixed
    DISPLAY_BOTH
    = 'both'
    
    
    
DISPLAY_FULL_NAME
    public
        mixed
    DISPLAY_FULL_NAME
    = 'full_name'
    
    
    
DISPLAY_USER_NAME
    public
        mixed
    DISPLAY_USER_NAME
    = 'user_name'
    
    
    
GENERATED_USER_NAME
    public
        mixed
    GENERATED_USER_NAME
    = 'user-%s-%s'
    
    
    
MENTION_REGEX
    public
        mixed
    MENTION_REGEX
    = '^\\[user=(.*?)\\]^'
    
    
    
NOT_AUTO_APPROVED_TAGGER_POST
    public
        mixed
    NOT_AUTO_APPROVED_TAGGER_POST
    = 1
    
    
    
THEME_ID_SETTING
    public
        mixed
    THEME_ID_SETTING
    = 'profile_theme_id'
    
    
    
THEME_PREFERENCE_NAMES
    public
        mixed
    THEME_PREFERENCE_NAMES
    = [self::THEME_TYPE_SETTING, self::THEME_ID_SETTING]
    
    
    
THEME_TYPE_SETTING
    public
        mixed
    THEME_TYPE_SETTING
    = 'profile_theme_type'
    
    
    
Properties
$relationRepository
    protected
        UserRelationRepositoryInterface
    $relationRepository
    
    
    
    
$repository
    private
        UserRepositoryInterface
    $repository
    
    
    
    
Methods
__construct()
    public
                    __construct(UserRepositoryInterface $repository, UserRelationRepositoryInterface $relationRepository) : mixed
    Parameters
- $repository : UserRepositoryInterface
 - $relationRepository : UserRelationRepositoryInterface
 
canViewLocation()
    public
                    canViewLocation(User $context, User $user) : bool
    Parameters
Return values
boolgetAddress()
    public
                    getAddress(User $context, User $user) : string|null
    Parameters
Tags
Return values
string|nullgetFirstName()
    public
                    getFirstName(string $name) : string
    Parameters
- $name : string
 
Return values
stringgetFriendship()
    public
                    getFriendship(User $user, User $targetUser) : int|null
    Parameters
Return values
int|nullgetGender()
    public
                    getGender(UserProfile $profile) : string|null
    Parameters
- $profile : UserProfile
 
Return values
string|nullgetGuestUser()
    public
                    getGuestUser() : Authenticatable
    Return values
AuthenticatablegetLastName()
    public
                    getLastName(string $name) : string
    Parameters
- $name : string
 
Return values
stringgetLocation()
    public
                    getLocation(User $context, User $resource) : array<string, mixed>
    Parameters
Return values
array<string, mixed>getLocationValue()
    public
                    getLocationValue(User $context, mixed $resource) : string
    Parameters
- $context : User
 - $resource : mixed
 
Return values
stringgetMentions()
    public
                    getMentions(string $content) : array<string|int, int>
    Parameters
- $content : string
 
Return values
array<string|int, int>getNotificationSettingsByChannel()
    public
                    getNotificationSettingsByChannel(User $user, string $channel) : array<int, mixed>
    Parameters
- $user : User
 - $channel : string
 
Return values
array<int, mixed>getPossessiveGender()
    public
                    getPossessiveGender(UserGender|null $gender) : string
    Parameters
- $gender : UserGender|null
 
Return values
stringgetShortName()
    public
                    getShortName(string $name) : string
    Parameters
- $name : string
 
Return values
stringgetSummary()
    public
                    getSummary(User $context, User $user) : string|null
    Parameters
Tags
Return values
string|nullgetTimeZoneForForm()
    public
                    getTimeZoneForForm() : array<int, mixed>
    Return values
array<int, mixed>getTimeZoneNameById()
    public
                    getTimeZoneNameById(int $id) : string|null
    Parameters
- $id : int
 
Return values
string|nullgetUserAge()
    public
                    getUserAge(string|null $birthday) : int|null
    Parameters
- $birthday : string|null
 
Tags
Return values
int|nullgetUsersByRoleId()
    public
                    getUsersByRoleId(int $roleId) : Collection|null
    Parameters
- $roleId : int
 
Return values
Collection|nullgetVideoSettings()
    public
                    getVideoSettings(User $user) : array<string, mixed>
    Parameters
- $user : User
 
Return values
array<string, mixed>hasPendingSubscription()
    public
                    hasPendingSubscription(Request $request, User $user[, bool $isMobile = false ]) : array<string|int, mixed>|null
    Parameters
- $request : Request
 - $user : User
 - $isMobile : bool = false
 
Return values
array<string|int, mixed>|nullisBan()
    public
                    isBan(int $userId) : bool
    Parameters
- $userId : int
 
Return values
boolisFollowing()
    public
                    isFollowing(User $context, User $user) : bool
    Parameters
Tags
Return values
boolsplitName()
    public
                    splitName(string $name) : array<string|int, mixed>
    Parameters
- $name : string
 
Return values
array<string|int, mixed>totalFollowers()
    public
                    totalFollowers(User $user) : int
    Parameters
- $user : User
 
Tags
Return values
intupdateInvisibleMode()
    public
                    updateInvisibleMode(User $context, int $isInvisible) : User
    Parameters
- $context : User
 - $isInvisible : int
 
Return values
UserupdateLastActivity()
    public
                    updateLastActivity(User $context) : bool
    Parameters
- $context : User
 
Return values
boolupdateLastLogin()
    public
                    updateLastLogin(User|null $context) : bool
    Parameters
- $context : User|null
 
Return values
boolupdateNotificationSettingsByChannel()
    public
                    updateNotificationSettingsByChannel(User $context, array<string, int> $attributes) : bool
    Parameters
- $context : User
 - $attributes : array<string, int>