Open Journal Systems  2.4.3
 All Classes Namespaces Functions Variables Groups Pages
PKPUserSettingsDAO Class Reference
Inheritance diagram for PKPUserSettingsDAO:
DAO UserSettingsDAO

Public Member Functions

 deleteSetting ($userId, $name, $assocType=null, $assocId=null)
 
 deleteSettings ($userId)
 
getSetting ($userId, $name, $assocType=null, $assocId=null)
 
getSettingsByAssoc ($userId, $assocType=null, $assocId=null)
 
getUsersBySetting ($name, $value, $type=null, $assocType=null, $assocId=null)
 
 PKPUserSettingsDAO ()
 
 updateSetting ($userId, $name, $value, $type=null, $assocType=null, $assocId=null)
 
- Public Member Functions inherited from DAO
 concat ()
 
 convertFromDB ($value, $type)
 
 convertToDB ($value, &$type)
 
 DAO ($dataSource=null, $callHooks=true)
 
 dateFromDB ($d)
 
 datetimeFromDB ($dt)
 
 datetimeToDB ($dt)
 
 dateToDB ($d)
 
 flushCache ()
 
 formatDateToDB ($date, $defaultNumWeeks=null, $acceptPastDate=true)
 
 getAffectedRows ()
 
 getDataChangedEvent ($elementId=null, $parentElementId=null)
 
getDataSource ()
 
 getDirectionMapping ($direction)
 
 getDriver ()
 
 getInsertId ($table= '', $id= '', $callHooks=true)
 
 getType ($value)
 
 replace ($table, $arrFields, $keyCols)
 
retrieve ($sql, $params=false, $callHooks=true)
 
retrieveCached ($sql, $params=false, $secsToCache=3600, $callHooks=true)
 
retrieveLimit ($sql, $params=false, $numRows=false, $offset=false, $callHooks=true)
 
retrieveRange ($sql, $params=false, $dbResultRange=null, $callHooks=true)
 
 setCacheDir ()
 
 setDataSource (&$dataSource)
 
 update ($sql, $params=false, $callHooks=true, $dieOnError=true)
 
 updateDataObjectSettings ($tableName, &$dataObject, $idArray)
 

Additional Inherited Members

- Public Attributes inherited from DAO
 $_dataSource
 

Detailed Description

Operations for retrieving and modifying user settings.

See Also
PKPUser

Definition at line 18 of file PKPUserSettingsDAO.inc.php.

Member Function Documentation

PKPUserSettingsDAO::deleteSetting (   $userId,
  $name,
  $assocType = null,
  $assocId = null 
)

Delete a user setting.

Parameters
$userIdint
$namestring
$assocTypeint
$assocIdint

Definition at line 192 of file PKPUserSettingsDAO.inc.php.

References DAO\update().

PKPUserSettingsDAO::deleteSettings (   $userId)

Delete all settings for a user.

Parameters
$userIdint

Definition at line 203 of file PKPUserSettingsDAO.inc.php.

References DAO\update().

& PKPUserSettingsDAO::getSetting (   $userId,
  $name,
  $assocType = null,
  $assocId = null 
)

Retrieve a user setting value.

Parameters
$userIdint
$name
$assocTypeint
$assocIdint
Returns
mixed

Definition at line 34 of file PKPUserSettingsDAO.inc.php.

References DAO\convertFromDB(), and DAO\retrieve().

& PKPUserSettingsDAO::getSettingsByAssoc (   $userId,
  $assocType = null,
  $assocId = null 
)

Retrieve all settings for a user by association info.

Parameters
$userIdint
$assocTypeint
$assocIdint
Returns
array

Definition at line 97 of file PKPUserSettingsDAO.inc.php.

References DAO\convertFromDB(), and DAO\retrieve().

& PKPUserSettingsDAO::getUsersBySetting (   $name,
  $value,
  $type = null,
  $assocType = null,
  $assocId = null 
)

Retrieve all users by setting name and value.

Parameters
$namestring
$valuemixed
$typestring
$assocTypeint
$assocIdint
Returns
DAOResultFactory matching Users

Definition at line 70 of file PKPUserSettingsDAO.inc.php.

References DAO\convertToDB(), DAORegistry\getDAO(), and DAO\retrieve().

PKPUserSettingsDAO::PKPUserSettingsDAO ( )

Constructor

Definition at line 22 of file PKPUserSettingsDAO.inc.php.

PKPUserSettingsDAO::updateSetting (   $userId,
  $name,
  $value,
  $type = null,
  $assocType = null,
  $assocId = null 
)

Add/update a user setting.

Parameters
$userIdint
$namestring
$valuemixed
$typestring data type of the setting. If omitted, type will be guessed
$assocTypeint
$assocIdint

Definition at line 132 of file PKPUserSettingsDAO.inc.php.

References DAO\convertToDB(), DAO\retrieve(), and DAO\update().


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