Squiz Matrix  4.12.2
 All Data Structures Namespaces Functions Variables Pages
User Class Reference
Inheritance diagram for User:
Asset MySource_Object Backend_User Ldap_User Public_User Simple_Edit_User Ipb_User System_User Ldap_Backend_User Ldap_Simple_Edit_User Root_User

Public Member Functions

 User ($assetid=0)
 
 reload ()
 
 _getAllowedLinks ()
 
 setAttrValue ($name, $value)
 
 processStatusChange ($new_status, $update_parents=TRUE)
 
 comparePassword ($entered_password)
 
 getValidUsername ($owning_attrid, $current_username)
 
 validatePassword ($passwd, $add_system_message=FALSE)
 
 getPasswordRulesDescription ()
 
 _getName ($short_name=FALSE)
 
 _checkPermissionAccess ($perm, $assetids=Array(), $only_workflow=TRUE)
 
 isDeletableLink ($linkid)
 
 canLogin ()
 
 canAccessBackend ()
 
 canSetAsCurrentUser ()
 
 getGroups ()
 
 getUserGroups ()
 
 _belongsToGroup ($group_assetid)
 
 getInboxLink ()
 
 getWorkspaceLink ()
 
getWorkspace ()
 
 printBody ()
 
 getUserLocks ()
 
 releaseUserLocks ()
 
 getAvailableKeywords ()
 
 getKeywordReplacement ($keyword)
 
 _uniqueAttributeExists ($owning_attrid, $assetid)
 
- Public Member Functions inherited from Asset
 Asset ($assetid=0)
 
 create (Array &$link)
 
 load ($assetid)
 
 _loadDataPaths ()
 
 reload ()
 
 canDelete ()
 
 delete ($release_lock=TRUE, $check_locked=TRUE)
 
 useSystemVersion ()
 
 loadSystemVersion ()
 
 saveSystemVersion ()
 
 clearSystemVersion ()
 
 revertToSystemVersion ()
 
 revertNoticeLinksToSystemVersion ()
 
 _updated ($update_parents=TRUE)
 
 type ()
 
 getTypeAncestors ($include_asset=TRUE)
 
 incrementVersion ($number='micro', $update_parents=TRUE)
 
 getLanguages ()
 
 setLanguages (Array $languages)
 
 setCharset ($charset)
 
 setForceSecure ($force_secure)
 
 remapAssetids (Array $map)
 
 morph ($new_type_code)
 
 _morphCleanup ($new_type_code)
 
 onRequestKeywords (Asset $broadcaster, Array $vars=Array())
 
 canClone ()
 
 cloneComponents (Asset $clone, Array $components, $override=FALSE)
 
 cloneComponentsAdditional (Asset $clone, Array $components)
 
 cloneLinks (Asset $clone)
 
 getStatus ()
 
 getAvailableStatii ()
 
 getStatusDescription ()
 
 processStatusChange ($new_status, $update_parents=TRUE, $run_updated=TRUE)
 
 setDate ($date_type, $time=NULL, $userid=NULL)
 
 lockTypes ()
 
 canForceablyAcquireLock ($lock_type)
 
 getEditingLocks ($keywords)
 
 _getAllowedLinks ()
 
 createLink (Asset $minor, $link_type, $value='', $sort_order=NULL, $dependant='0', $exclusive='0', $moving=FALSE, $locked=0)
 
 prepareLink (Asset $asset, $side_of_link, &$link_type, &$value, &$sort_order, &$dependant, &$exclusive)
 
 canCreateLink (Asset $minor, $link_type, $exclusive)
 
 canMoveLink (Asset $minor, Asset $old_major, $link_type)
 
 describeLink ($linkid)
 
 isDeletableLink ($linkid)
 
 canDeleteLink ($linkid)
 
 deleteLink ($linkid, $check_locked=TRUE)
 
 linksUpdated ()
 
 canCloneLink ()
 
 saveAttributes ($dont_run_updated=FALSE, $log_message=TRUE)
 
 setAttrValue ($name, $value)
 
 attr ($name)
 
attrByRef ($name)
 
 getAttribute ($name, $mute_errors=FALSE)
 
 getAssetKeywords ($descriptions=FALSE)
 
 getAvailableKeywords ()
 
 getKeywordReplacement ($keyword)
 
 getAssetWebPathKeywordReplacement ()
 
 getCustomKeywordReplacements ($keywords=Array(), $invoke_backend=FALSE)
 
 processCustomKeywords ($keywords=Array())
 
 getContent ()
 
 setContent ()
 
 getEffectiveLastUpdatedTime ($assetids)
 
 readAccess (Array $assetids=Array())
 
 writeAccess ($lock_type='', Array $assetids=Array(), $only_workflow=TRUE)
 
 adminAccess ($lock_type='', Array $assetids=Array())
 
 backendAccess ()
 
 liveEditAccess ($lock_type)
 
 canliveEdit ($lock_type)
 
 effectiveUnrestricted ()
 
 checkAccess ($perm, $lock_type, Array $assetids=Array(), $only_workflow=TRUE)
 
 accessEffective ()
 
 permissionsUpdated ()
 
 printFrontend ()
 
 printFrontendAsset (Asset $asset, $design=NULL)
 
 getValidProtocols ()
 
 printHead ()
 
 printBody ()
 
 getCurrentPaintLayoutName ()
 
 getCurrentDesignName ()
 
 printBodyWithPaintLayout ($layout_id='')
 
 initLimbo ()
 
 printLimbo ()
 
 paintBackend (Backend_Outputter $o)
 
 getPrefix ()
 
 processBackend (Backend_Outputter $o, Array &$link)
 
 getEI ()
 
 getEditFns ()
 
 getBackendHref ($screen='', $backend_page=TRUE)
 
 getURL ($base_url=NULL, $ignore_rollback=FALSE, $base_contextid=NULL)
 
 getURLs ()
 
 getHref ($base_url=NULL, $ignore_rollback=FALSE)
 
 getWebDataPath ()
 
 getWebPaths ()
 
 saveWebPaths ($paths, $auto_add_remaps=TRUE)
 
 getLookups ($field='')
 
 getDesignLookups ()
 
 getLookupValues ($inherited=NULL, $prefix='', $like_search=TRUE, $ignore_override=FALSE)
 
 deleteLookupValue ($layout_name, $layout_value)
 
 setPaintLayouts ($layouts)
 
 updateLookups ($auto_add_remaps=TRUE)
 
 setLookupValues (Array $values)
 
 getAssetStatusDescriptionKeywordReplacement ()
 
 getAssetStatusColourKeywordReplacement ()
 
 replaceKeywordsInString ($string)
 
 fastTrack ($tasks)
 
 unFastTrack ($tasks)
 
 shouldFastTrack ($task, $assetid=NULL)
 
 getFaskTrackedTaskAssetids ($task)
 
 getDependantParentsURL ()
 
- Public Member Functions inherited from MySource_Object
 MySource_Object ()
 
 __sleep ()
 
 __wakeup ()
 

Protected Member Functions

 _preCreateCheck (Array &$link)
 
 _createAdditional (Array &$link)
 
 _catchBlankUserNamePass ($username, $password)
 
 _catchBlankSetUserName ($username)
 
- Protected Member Functions inherited from Asset
 _preCreateCheck (Array &$link)
 
 _createAdditional (Array &$link)
 
 _abortCreate ($trigger_level_changed=FALSE, $linkid=0)
 
 _loadVars ()
 
 _getName ($short_name=FALSE, $contextid=NULL)
 
 _getKeywordReplacement ($keyword)
 
 _checkPermissionAccess ($perm, $assetids=Array(), $only_workflow=TRUE)
 
 makeAndSaveInitialWebPath ($path, $parent_link=NULL)
 

Additional Inherited Members

- Data Fields inherited from Asset
 $id = 0
 
 $version = ''
 
 $name = ''
 
 $short_name = ''
 
 $status
 
 $languages = ''
 
 $charset = ''
 
 $force_secure = '0'
 
 $created
 
 $created_userid
 
 $updated
 
 $updated_userid
 
 $published
 
 $published_userid
 
 $status_changed
 
 $status_changed_userid
 
 $_is_cacheable = FALSE
 
 $vars = Array()
 
 $_available_keywords = Array()
 
 $data_path_suffix = ''
 
 $data_path = ''
 
 $data_path_public = ''
 
 $_ser_attrs = FALSE
 

Detailed Description

Definition at line 37 of file user.inc.

Member Function Documentation

_belongsToGroup (   $group_assetid)

Verify if a user belongs to a given group, return TRUE if we are

Here is where we call the user conditions and certify the result. When a new user condition is added, please add the specifics for calling it here.

Parameters
string$group_assetidassetid of the group in question
Returns
boolean private

Definition at line 845 of file user.inc.

_catchBlankSetUserName (   $username)
protected

Catches blank username being set during setAttrValue()

Override this and return TRUE if a specific subclass wants to skip this check

Parameters
string$usernamethe passed user name
Returns
boolean public

Definition at line 988 of file user.inc.

_catchBlankUserNamePass (   $username,
  $password 
)
protected

Catches blank username/password combination made during create()

Override this and return TRUE if a specific subclass wants to skip this check

Parameters
string$usernamethe passed user name
string$passwordthe passed pass
Returns
boolean public

Definition at line 971 of file user.inc.

_checkPermissionAccess (   $perm,
  $assetids = Array(),
  $only_workflow = TRUE 
)

Returns TRUE if at least one of the passed assetids has the passed permission Does not check current status of lock

Parameters
int$permthe permission to check access for
array$assetidsAn array of user_group and/or user ids to check for permission If the array is empty, the current user will be checked
boolean$only_workflowcheck only workflow
Returns
boolean public

Definition at line 659 of file user.inc.

_createAdditional ( Array &  $link)
protected

Perform any additional processing required during the creation of this asset

Standard pages create a bodycopy asset when they are created

Parameters
array&$linkinformation used to create the initial link
Returns
boolean private

Definition at line 98 of file user.inc.

_getAllowedLinks ( )

Returns an array of all the permitted link type, the type asset and the cardinality

Returns
array private
See Also
Asset::_getAllowLinks()

Definition at line 159 of file user.inc.

_getName (   $short_name = FALSE)

Returns name of the user

Parameters
boolean$short_namewhether or not we are after the shortname or the full name
Returns
string private
See Also
Asset::_getName()

Definition at line 640 of file user.inc.

_preCreateCheck ( Array &  $link)
protected

Perform any pre-validation required during the creation of this asset

Users ensure a username and password has been set before they are created

Parameters
array&$linkinformation used to create the initial link
Returns
boolean private

Definition at line 64 of file user.inc.

_uniqueAttributeExists (   $owning_attrid,
  $assetid 
)

Test if a unique attribute exists in db

Parameters
string$owning_attridThe attribute id of the owning attribute
string$assetidThe asset id
Returns
Boolean private

Definition at line 1144 of file user.inc.

canAccessBackend ( )

Check if this user can access the backend interface

This will be disabled by default for a standard user, and enabled for users who are allowed backend access (eg. backend user).

Returns
boolean public

Definition at line 760 of file user.inc.

canLogin ( )

Check if this user can log in Note that this is not for backend logins only, it applys to all logins

Returns
boolean public

Definition at line 734 of file user.inc.

canSetAsCurrentUser ( )

Can we set this as the current user?

Returns
boolean public

Definition at line 773 of file user.inc.

comparePassword (   $entered_password)

Returns whether the passed password matches this users' password

Parameters
string$entered_passwordthe password sent to us
Returns
boolean public

Definition at line 334 of file user.inc.

getAvailableKeywords ( )

Return the keywords for this asset type.

Returns
array public

Definition at line 1055 of file user.inc.

getGroups ( )

Get all the groups that this user is in, regardless of group security restrictions

Returns a list of assetids of the matching groups The result is stored in the session for faster access

Returns
array public

Definition at line 789 of file user.inc.

getInboxLink ( )

Returns the link to the inbox

Returns
array public

Definition at line 882 of file user.inc.

getKeywordReplacement (   $keyword)

Get bodycopy keyword replacement

Parameters
string$keywordKeyword to find a replacement for
Returns
string public
See Also
_getKeywordReplacement

Definition at line 1078 of file user.inc.

getPasswordRulesDescription ( )

Get a description of the password rules currently in effect

Returns
string public

Definition at line 544 of file user.inc.

getUserGroups ( )

Gets all the groups that this user is in and for which this user satisfies the security restrictions

Returns a list of assetids of the matching groups.

Returns
array public

Definition at line 812 of file user.inc.

getUserLocks ( )

Returns an array of the current locks that this user holds

...or FALSE if there is no support for it in this locking method (requires ability to get active locks).

Returns
array|boolean public

Definition at line 1008 of file user.inc.

getValidUsername (   $owning_attrid,
  $current_username 
)

Returns next available username

Parameters
string$owning_attridThe attribute id of the owning attribute
string$current_usernameThe current username
Returns
string|FALSE (on error) public

Definition at line 354 of file user.inc.

& getWorkspace ( )

Returns this user's Workspace

Returns
object public

Definition at line 908 of file user.inc.

getWorkspaceLink ( )

Returns the link to the workspace

Returns
array public

Definition at line 895 of file user.inc.

isDeletableLink (   $linkid)

Returns TRUE if we can delete the passed link, or a string with the error msg

Parameters
int$linkidthe link id of the link to remove
Returns
mixed boolean|string public

Definition at line 707 of file user.inc.

printBody ( )

Called by the design to print the body of this asset

Returns
void public

Definition at line 934 of file user.inc.

processStatusChange (   $new_status,
  $update_parents = TRUE 
)

Provides extra checking and disable invalid status change on errors

Parameters
int$new_statusthe new status to set for this asset
boolean$update_parentsSpecify if we want to update the parent as well
Returns
boolean public

Definition at line 230 of file user.inc.

releaseUserLocks ( )

Releases all locks that this user currently holds in the system

Returns
void public

Definition at line 1038 of file user.inc.

reload ( )

Reload this asset from the DB, clearing all its local caches

Returns
void public

Definition at line 144 of file user.inc.

setAttrValue (   $name,
  $value 
)

Set the value for the passed variable to the passed value

Overwritten here to check inputs (username and password) and to encrypt password before setting value

Parameters
string$namethe name of the attribute
string$valuethe new value of the attribute
Returns
boolean public

Definition at line 188 of file user.inc.

User (   $assetid = 0)

Constructor

Parameters
int$assetidthe asset id to be loaded

Definition at line 46 of file user.inc.

validatePassword (   $passwd,
  $add_system_message = FALSE 
)

Validates the passed password against a list of rules

Parameters
string$passwdthe password to validate
boolean$add_system_messageIf true, adds a system message instead of triggering errors
Returns
boolean public

Definition at line 392 of file user.inc.


The documentation for this class was generated from the following file: