VuFind API Documentation

Search extends RowGateway
in package
implements SearchEntityInterface, DbTableAwareInterface, DbServiceAwareInterface Uses DbTableAwareTrait, DbServiceAwareTrait

Row Definition for search

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

Interfaces, Classes, Traits and Enums

SearchEntityInterface
Entity model interface for search table
DbTableAwareInterface
Marker interface for classes that depend on the \VuFind\Db\Table\PluginManager
DbServiceAwareInterface
Marker interface for classes that depend on the \VuFind\Db\Service\PluginManager

Table of Contents

$checksum  : int|null
$created  : string
$id  : int
$last_notification_sent  : string
$notification_base_url  : string
$notification_frequency  : int
$saved  : int
$search_object  : string
$session_id  : string|null
$title  : string|null
$user_id  : int
$dbServiceManager  : PluginManager
Database service plugin manager
$tableManager  : PluginManager
Database table plugin manager
__construct()  : mixed
Constructor
getChecksum()  : int|null
Get checksum.
getCreated()  : DateTime
Get created date.
getDbService()  : T
Get a database service object.
getDbServiceManager()  : PluginManager
Get the service plugin manager. Throw an exception if it is missing.
getDbTable()  : Gateway
Get a database table object.
getDbTableManager()  : PluginManager
Get the table plugin manager. Throw an exception if it is missing.
getId()  : int|null
Get identifier (returns null for an uninitialized or non-persisted object).
getLastNotificationSent()  : DateTime
When was the last notification sent?
getNotificationBaseUrl()  : string
Get notification base URL.
getNotificationFrequency()  : int
Get notification frequency.
getPrimaryKeyColumn()  : array<string|int, mixed>
Retrieve primary key information.
getSaved()  : bool
Get saved.
getSearchObject()  : Minified|null
Get the search object from the row.
getSearchObjectOrThrowException()  : Minified
Get the search object from the row, and throw an exception if it is missing.
getSessionId()  : string|null
Get session identifier.
getTitle()  : string|null
Get title.
getUnsubscribeSecret()  : string
Utility function for generating a token for unsubscribing a saved search.
getUser()  : UserEntityInterface|null
Get user.
save()  : int
Save
setChecksum()  : SearchEntityInterface
Set checksum.
setCreated()  : SearchEntityInterface
Set created date.
setDbServiceManager()  : void
Set the service plugin manager.
setDbTableManager()  : void
Set the table plugin manager.
setLastExecuted()  : mixed
Set last executed time for scheduled alert.
setLastNotificationSent()  : SearchEntityInterface
Set when last notification was sent.
setNotificationBaseUrl()  : SearchEntityInterface
Set notification base URL.
setNotificationFrequency()  : SearchEntityInterface
Set notification frequency.
setSaved()  : SearchEntityInterface
Set saved.
setSchedule()  : mixed
Set schedule for scheduled alert.
setSearchObject()  : SearchEntityInterface
Set search object.
setSessionId()  : SearchEntityInterface
Set session identifier.
setTitle()  : SearchEntityInterface
Set title.
setUser()  : SearchEntityInterface
Set user.
normalizeSearchObject()  : void
Support method to make sure that the search_object field is formatted as a string, since PostgreSQL sometimes represents it as a resource.

Properties

$checksum

public int|null $checksum

$last_notification_sent

public string $last_notification_sent

$notification_base_url

public string $notification_base_url

$notification_frequency

public int $notification_frequency

$search_object

public string $search_object

$session_id

public string|null $session_id

Methods

__construct()

Constructor

public __construct(Adapter $adapter) : mixed
Parameters
$adapter : Adapter

Database adapter

Return values
mixed

getChecksum()

Get checksum.

public getChecksum() : int|null
Return values
int|null

getCreated()

Get created date.

public getCreated() : DateTime
Return values
DateTime

getDbService()

Get a database service object.

public getDbService(class-string<\VuFind\Db\Service\T> $name) : T
Parameters
$name : class-string<\VuFind\Db\Service\T>

Name of service to retrieve

Tags
template

T

Return values
T

getDbTable()

Get a database table object.

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

Table to load.

Return values
Gateway

getId()

Get identifier (returns null for an uninitialized or non-persisted object).

public getId() : int|null
Return values
int|null

getLastNotificationSent()

When was the last notification sent?

public getLastNotificationSent() : DateTime
Return values
DateTime

getNotificationBaseUrl()

Get notification base URL.

public getNotificationBaseUrl() : string
Return values
string

getNotificationFrequency()

Get notification frequency.

public getNotificationFrequency() : int
Return values
int

getPrimaryKeyColumn()

Retrieve primary key information.

public getPrimaryKeyColumn() : array<string|int, mixed>
Return values
array<string|int, mixed>

getSaved()

Get saved.

public getSaved() : bool
Return values
bool

getSearchObject()

Get the search object from the row.

public getSearchObject() : Minified|null
Return values
Minified|null

getSearchObjectOrThrowException()

Get the search object from the row, and throw an exception if it is missing.

public getSearchObjectOrThrowException() : Minified
Tags
throws
Exception
deprecated
Return values
Minified

getSessionId()

Get session identifier.

public getSessionId() : string|null
Return values
string|null

getTitle()

Get title.

public getTitle() : string|null
Return values
string|null

getUnsubscribeSecret()

Utility function for generating a token for unsubscribing a saved search.

public getUnsubscribeSecret(HMAC $hmac, UserEntityInterface $user) : string
Parameters
$hmac : HMAC

HMAC hash generator

$user : UserEntityInterface

User object

Tags
deprecated

Use \VuFind\Crypt\SecretCalculator::getSearchUnsubscribeSecret()

Return values
string

token

save()

Save

public save() : int
Return values
int

setLastExecuted()

Set last executed time for scheduled alert.

public setLastExecuted(string $time) : mixed
Parameters
$time : string

Time.

Tags
deprecated
Return values
mixed

setLastNotificationSent()

Set when last notification was sent.

public setLastNotificationSent(DateTime $lastNotificationSent) : SearchEntityInterface
Parameters
$lastNotificationSent : DateTime

Time when last notification was sent

Return values
SearchEntityInterface

setNotificationFrequency()

Set notification frequency.

public setNotificationFrequency(int $notificationFrequency) : SearchEntityInterface
Parameters
$notificationFrequency : int

Notification frequency

Return values
SearchEntityInterface

setSchedule()

Set schedule for scheduled alert.

public setSchedule(int $schedule[, string $url = null ]) : mixed
Parameters
$schedule : int

Schedule.

$url : string = null

Site base URL

Tags
deprecated
Return values
mixed

normalizeSearchObject()

Support method to make sure that the search_object field is formatted as a string, since PostgreSQL sometimes represents it as a resource.

protected normalizeSearchObject() : void
Return values
void

Search results