Open Monograph Press  1.1
 All Classes Namespaces Functions Variables Groups Pages
AccessKeyDAO Class Reference
Inheritance diagram for AccessKeyDAO:
DAO

Public Member Functions

_returnAccessKeyFromRow ($row)
 
 AccessKeyDAO ()
 
 deleteAccessKeyById ($accessKeyId)
 
 deleteExpiredKeys ()
 
 deleteObject (&$accessKey)
 
getAccessKey ($accessKeyId)
 
getAccessKeyByKeyHash ($context, $userId, $keyHash, $assocId=null)
 
getAccessKeyByUserId ($context, $userId)
 
 getInsertId ()
 
 insertObject ($accessKey)
 
 newDataObject ()
 
 transferAccessKeys ($oldUserId, $newUserId)
 
 updateObject (&$accessKey)
 
- 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 ()
 
getDataSource ()
 
 getDirectionMapping ($direction)
 
 getDriver ()
 
 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

- Static Public Member Functions inherited from DAO
static getDataChangedEvent ($elementId=null, $parentElementId=null)
 
- Public Attributes inherited from DAO
 $_dataSource
 
- Protected Member Functions inherited from DAO
 _getInsertId ($table= '', $id= '')
 

Detailed Description

Operations for retrieving and modifying AccessKey objects.

See Also
AccessKey

Definition at line 20 of file AccessKeyDAO.inc.php.

Member Function Documentation

& AccessKeyDAO::_returnAccessKeyFromRow (   $row)

Internal function to return an AccessKey object from a row.

Parameters
$rowarray
Returns
AccessKey

Definition at line 113 of file AccessKeyDAO.inc.php.

References HookRegistry\call(), DAO\datetimeFromDB(), and newDataObject().

Referenced by getAccessKey(), getAccessKeyByKeyHash(), and getAccessKeyByUserId().

AccessKeyDAO::AccessKeyDAO ( )

Constructor

Definition at line 24 of file AccessKeyDAO.inc.php.

AccessKeyDAO::deleteAccessKeyById (   $accessKeyId)

Delete an accessKey by ID.

Parameters
$accessKeyIdint

Definition at line 187 of file AccessKeyDAO.inc.php.

References DAO\update().

Referenced by deleteObject().

AccessKeyDAO::deleteExpiredKeys ( )

Delete expired access keys.

Definition at line 209 of file AccessKeyDAO.inc.php.

References DAO\datetimeToDB(), Core\getCurrentDate(), and DAO\update().

AccessKeyDAO::deleteObject ( $accessKey)

Delete an accessKey.

Parameters
$accessKeyAccessKey

Definition at line 179 of file AccessKeyDAO.inc.php.

References deleteAccessKeyById().

& AccessKeyDAO::getAccessKey (   $accessKeyId)

Retrieve an accessKey by ID.

Parameters
$accessKeyIdint
Returns
AccessKey

Definition at line 33 of file AccessKeyDAO.inc.php.

References _returnAccessKeyFromRow(), DAO\datetimeToDB(), Core\getCurrentDate(), and DAO\retrieve().

& AccessKeyDAO::getAccessKeyByKeyHash (   $context,
  $userId,
  $keyHash,
  $assocId = null 
)

Retrieve a accessKey object by key.

Parameters
$contextstring
$userIdint
$keyHashstring
$assocIdint
Returns
AccessKey

Definition at line 81 of file AccessKeyDAO.inc.php.

References _returnAccessKeyFromRow(), DAO\datetimeToDB(), Core\getCurrentDate(), and DAO\retrieve().

& AccessKeyDAO::getAccessKeyByUserId (   $context,
  $userId 
)

Retrieve a accessKey object user ID.

Parameters
$contextstring
$userIdint
Returns
AccessKey

Definition at line 56 of file AccessKeyDAO.inc.php.

References _returnAccessKeyFromRow(), DAO\datetimeToDB(), Core\getCurrentDate(), and DAO\retrieve().

AccessKeyDAO::getInsertId ( )

Get the ID of the last inserted accessKey.

Returns
int

Definition at line 222 of file AccessKeyDAO.inc.php.

References DAO\_getInsertId().

Referenced by insertObject().

AccessKeyDAO::insertObject (   $accessKey)

Insert a new accessKey.

Parameters
$accessKeyAccessKey

Definition at line 131 of file AccessKeyDAO.inc.php.

References DAO\datetimeToDB(), getInsertId(), and DAO\update().

AccessKeyDAO::newDataObject ( )

Instantiate and return a new data object.

Returns
AccessKey

Definition at line 104 of file AccessKeyDAO.inc.php.

Referenced by _returnAccessKeyFromRow().

AccessKeyDAO::transferAccessKeys (   $oldUserId,
  $newUserId 
)

Transfer access keys to another user ID.

Parameters
$oldUserIdint
$newUserIdint

Definition at line 199 of file AccessKeyDAO.inc.php.

References DAO\update().

AccessKeyDAO::updateObject ( $accessKey)

Update an existing accessKey.

Parameters
$accessKeyAccessKey

Definition at line 154 of file AccessKeyDAO.inc.php.

References DAO\datetimeToDB(), and DAO\update().


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