VuFind API Documentation

User extends Gateway
in package

Table Definition for user

Tags
category

VuFind

author

Demian Katz demian.katz@villanova.edu

license

http://opensource.org/licenses/gpl-2.0.php GNU General Public License

link

Main Site

Table of Contents

$config  : Config
VuFind configuration
$session  : Container
Session container
$tableManager  : PluginManager
Table manager
__construct()  : mixed
Constructor
beginTransaction()  : void
Begin a database transaction.
commitTransaction()  : void
Commit a database transaction.
createRow()  : object
Create a new row.
createRowForUsername()  : User
Create a row for the specified username.
getByCatalogId()  : User|null
Retrieve a user object from the database based on catalog ID.
getByEmail()  : User|null
Retrieve a user object from the database based on email.
getById()  : User|null
Retrieve a user object from the database based on ID.
getByUsername()  : User|null
Retrieve a user object from the database based on username; when requested, create a new row if no existing match is found.
getByVerifyHash()  : User|null
Return a row by a verification hash
getDbTable()  : Gateway
Get access to another table.
getInsecureRows()  : mixed
Get user rows with insecure passwords and/or catalog passwords
initializeFeatures()  : void
Initialize features
rollBackTransaction()  : void
Roll back a database transaction.

Properties

$config

VuFind configuration

protected Config $config

$session

Session container

protected Container $session

Methods

__construct()

Constructor

public __construct(Adapter $adapter, PluginManager $tm, array<string|int, mixed> $cfg, RowGateway $rowObj, Config $config[, Container $session = null ][, string $table = 'user' ]) : mixed
Parameters
$adapter : Adapter

Database adapter

$tm : PluginManager

Table manager

$cfg : array<string|int, mixed>

Laminas configuration

$rowObj : RowGateway

Row prototype object (null for default)

$config : Config

VuFind configuration

$session : Container = null

Session container to inject into rows (optional; used for privacy mode)

$table : string = 'user'

Name of database table to interface with

Return values
mixed

beginTransaction()

Begin a database transaction.

public beginTransaction() : void
Tags
throws
Exception
Return values
void

commitTransaction()

Commit a database transaction.

public commitTransaction() : void
Tags
throws
Exception
Return values
void

createRow()

Create a new row.

public createRow() : object
Return values
object

createRowForUsername()

Create a row for the specified username.

public createRowForUsername(string $username) : User
Parameters
$username : string

Username

Return values
User

getByCatalogId()

Retrieve a user object from the database based on catalog ID.

public getByCatalogId(string $catId) : User|null
Parameters
$catId : string

Catalog ID.

Return values
User|null

getByEmail()

Retrieve a user object from the database based on email.

public getByEmail(string $email) : User|null
Parameters
$email : string

email to use for retrieval.

Return values
User|null

getById()

Retrieve a user object from the database based on ID.

public getById(int $id) : User|null
Parameters
$id : int

ID.

Return values
User|null

getByUsername()

Retrieve a user object from the database based on username; when requested, create a new row if no existing match is found.

public getByUsername(string $username[, bool $create = true ]) : User|null
Parameters
$username : string

Username to use for retrieval.

$create : bool = true

Should we create users that don't already exist?

Return values
User|null

getByVerifyHash()

Return a row by a verification hash

public getByVerifyHash(string $hash) : User|null
Parameters
$hash : string

User-unique hash string

Return values
User|null

getDbTable()

Get access to another table.

public getDbTable(string $table) : Gateway
Parameters
$table : string

Table name

Return values
Gateway

getInsecureRows()

Get user rows with insecure passwords and/or catalog passwords

public getInsecureRows() : mixed
Return values
mixed

initializeFeatures()

Initialize features

public initializeFeatures(array<string|int, mixed> $cfg) : void
Parameters
$cfg : array<string|int, mixed>

Laminas configuration

Return values
void

rollBackTransaction()

Roll back a database transaction.

public rollBackTransaction() : void
Tags
throws
Exception
Return values
void

Search results