Properties

$id

$id : String

Login name of the user.

Type

String

$hasAdmin

$hasAdmin : Boolean

User is an admin?

Type

Boolean

$rights

$rights : array

User rights map. In the format Array( "repoid" => "rw | r | nothing" )

Type

array

$prefs

$prefs : array

User preferences array in the format Array( "preference_key" => "preference_value" )

Type

array

$bookmarks

$bookmarks : array

User bookmarks array in the format Array( "repoid" => Array( Array( "path"=>"/path/to/bookmark", "title"=>"bookmark" )))

Type

array

$version

$version : string

User version(?) possibly deprecated.

Type

string

$parentUser

$parentUser : string

Type

string

$groupPath

$groupPath : 

Type

$storage

$storage : \Pydio\Conf\Core\AbstractConfDriver

Conf Storage implementation - Any class/plugin implementing AbstractConfDriver.

This is set by the constructor.

Type

\Pydio\Conf\Core\AbstractConfDriver

$debugEnabled

$debugEnabled : 

Whether queries will be logged with AJXP_Logger

Type

$hidden

$hidden : boolean

Type

boolean

$lastSessionSerialization

$lastSessionSerialization : 

Type

Methods

setHidden()

setHidden(boolean  $hidden) 

Set user as "hidden" ( = shared )

Parameters

boolean $hidden

isHidden()

isHidden() : boolean

Check if user is hidden

Returns

boolean

__construct()

__construct(  $id, null  $storage = null,   $debugEnabled = false) : \Pydio\Conf\Sql\SqlUser

AJXP_User Constructor

Parameters

$id

String User login name.

null $storage

AbstractConfDriver User storage implementation.

$debugEnabled

Returns

\Pydio\Conf\Sql\SqlUser

getId()

getId() : string

Returns

string

setId()

setId(string  $id) 

Parameters

string $id

storageExists()

storageExists() : boolean

Does the configuration storage exist? Will return true if all schema objects are available.

Returns

boolean —

false if storage does not exist

removeRole()

removeRole(string  $roleId) 

Parameters

string $roleId

Throws

\Exception

updateRolesOrder()

updateRolesOrder(array  $orderedRolesIds) 

Parameters

array $orderedRolesIds

array of roles ids

getProfile()

getProfile() : string

Returns

string

setProfile()

setProfile(string  $profile) 

Parameters

string $profile

setLock()

setLock(string  $lockAction) 

Parameters

string $lockAction

Throws

\Exception

removeLock()

removeLock(  $lockAction) 

Parameters

$lockAction

Throws

\Exception

getLock()

getLock() : boolean|mixed

Returns

boolean|mixed

hasLockByName()

hasLockByName(  $lockAction) : string|false

Parameters

$lockAction

Returns

string|false

isAdmin()

isAdmin() : boolean

Returns

boolean

setAdmin()

setAdmin(boolean  $boolean) 

Parameters

boolean $boolean

hasParent()

hasParent() : boolean

Returns

boolean

setParent()

setParent(string  $user) 

Parameters

string $user

A user ID

getParent()

getParent() : string

Returns

string

canRead()

canRead(string  $repositoryId) : boolean

Parameters

string $repositoryId

Returns

boolean

canWrite()

canWrite(string  $repositoryId) : boolean

Parameters

string $repositoryId

Returns

boolean

canAccessRepository()

canAccessRepository(\Pydio\Core\Model\RepositoryInterface|string  $idOrObject) : boolean

Parameters

\Pydio\Core\Model\RepositoryInterface|string $idOrObject

Returns

boolean

canSwitchTo()

canSwitchTo(integer  $repositoryId) : boolean

Test if user can switch to this repository

Parameters

integer $repositoryId

Returns

boolean

getPref()

getPref(  $prefName) : mixed|string

Parameters

$prefName

Returns

mixed|string

setPref()

setPref(string  $prefName, string|object  $prefValue) : null

Set a user preference.

Parameters

string $prefName

Name of the preference.

string|object $prefValue

Value to assign to the preference.

Returns

null —

or -1 on error.

setArrayPref()

setArrayPref(string  $prefName, string  $prefPath, mixed  $prefValue) 

Parameters

string $prefName
string $prefPath
mixed $prefValue

getArrayPref()

getArrayPref(  $prefName,   $prefPath) : mixed|string

Parameters

$prefName
$prefPath

Returns

mixed|string

addBookmark()

addBookmark(  $repositoryId, string  $path, string  $title) : 

Add a user bookmark.

Parameters

$repositoryId
string $path
string $title

Returns

removeBookmark()

removeBookmark(string  $repositoryId, string  $path) 

Parameters

string $repositoryId
string $path

renameBookmark()

renameBookmark(string  $repositoryId, string  $path, string  $title) : null

Rename a user bookmark.

Parameters

string $repositoryId
string $path

Path of the bookmark to rename.

string $title

New title to give the bookmark.

Returns

null —

or -1 on error.

getBookmarks()

getBookmarks(  $repositoryId) : array

Parameters

$repositoryId

Returns

array

load()

load() : mixed

Load initial user data (Rights, Preferences and Bookmarks).

Returns

mixed

save()

save(string  $context = "superuser") 

Parameters

string $context

getTemporaryData()

getTemporaryData(string  $key) : mixed

Get Temporary Data.

Implementation uses serialised files because of the overhead incurred with a full db implementation.

Parameters

string $key

String key of data to retrieve

Returns

mixed —

Requested value

saveTemporaryData()

saveTemporaryData(string  $key, mixed  $value) : mixed|void

Save Temporary Data.

Implementation uses serialised files because of the overhead incurred with a full db implementation.

Parameters

string $key

String key of data to save.

mixed $value

Value to save

Returns

mixed|void

setGroupPath()

setGroupPath(String  $groupPath, boolean  $update = false) 

Parameters

String $groupPath
boolean $update

Throws

\Pydio\Core\Exception\UserNotFoundException

getGroupPath()

getGroupPath() : null|string

Returns

null|string

getRealGroupPath()

getRealGroupPath(  $baseGroup) : string

Automatically set the group to the current user base

Parameters

$baseGroup

Returns

string

canAdministrate()

canAdministrate(\Pydio\Conf\Core\IGroupPathProvider  $provider) : boolean

Check if the current user can administrate the GroupPathProvider object

Parameters

\Pydio\Conf\Core\IGroupPathProvider $provider

Returns

boolean

canSee()

canSee(\Pydio\Conf\Core\IGroupPathProvider  $provider) : boolean

Check if the current user can assign administration for the GroupPathProvider object

Parameters

\Pydio\Conf\Core\IGroupPathProvider $provider

Returns

boolean

recomputeMergedRole()

recomputeMergedRole() 

Rebuild the current merged role

getRolesKeys()

getRolesKeys() : array

Returns

array

__sleep()

__sleep() : array

Returns

array

__wakeup()

__wakeup() 

reloadRolesIfRequired()

reloadRolesIfRequired() : boolean

Throws

\Exception

Returns

boolean

log()

log(string  $textMessage, string  $severityLevel = LOG_LEVEL_DEBUG) : null

Log a message if the logQueries property is true.

Parameters

string $textMessage

String text of the message to log

string $severityLevel

Integer constant of the logging severity

Returns

null

_save()

_save(String  $context = "superuser") : mixed|void

Save user rights, preferences and bookmarks.

Parameters

String $context

Returns

mixed|void

migrateRightsToPersonalRole()

migrateRightsToPersonalRole() : integer

Returns

integer

orderRoles()

orderRoles(  $r1,   $r2) : integer

Parameters

$r1
$r2

Returns

integer

filterRolesForSaving()

filterRolesForSaving(array  $roles, boolean  $checkBoolean) : array

Parameters

array $roles
boolean $checkBoolean

Returns

array