Search
extends RowGateway
in package
implements
SearchEntityInterface, DbTableAwareInterface, DbServiceAwareInterface
Uses
DbTableAwareTrait, DbServiceAwareTrait
Row Definition for search
Tags
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
$created
public
string
$created
$id
public
int
$id
$last_notification_sent
public
string
$last_notification_sent
$notification_base_url
public
string
$notification_base_url
$notification_frequency
public
int
$notification_frequency
$saved
public
int
$saved
$search_object
public
string
$search_object
$session_id
public
string|null
$session_id
$title
public
string|null
$title
$user_id
public
int
$user_id
$dbServiceManager
Database service plugin manager
protected
PluginManager
$dbServiceManager
$tableManager
Database table plugin manager
protected
PluginManager
$tableManager
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
Return values
T —getDbServiceManager()
Get the service plugin manager. Throw an exception if it is missing.
public
getDbServiceManager() : PluginManager
Tags
Return values
PluginManager —getDbTable()
Get a database table object.
public
getDbTable(string $table) : Gateway
Parameters
- $table : string
-
Table to load.
Return values
Gateway —getDbTableManager()
Get the table plugin manager. Throw an exception if it is missing.
public
getDbTableManager() : PluginManager
Tags
Return values
PluginManager —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
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
Return values
string —token
getUser()
Get user.
public
getUser() : UserEntityInterface|null
Return values
UserEntityInterface|null —save()
Save
public
save() : int
Return values
int —setChecksum()
Set checksum.
public
setChecksum(int|null $checksum) : SearchEntityInterface
Parameters
- $checksum : int|null
-
Checksum
Return values
SearchEntityInterface —setCreated()
Set created date.
public
setCreated(DateTime $dateTime) : SearchEntityInterface
Parameters
- $dateTime : DateTime
-
Created date
Return values
SearchEntityInterface —setDbServiceManager()
Set the service plugin manager.
public
setDbServiceManager(PluginManager $manager) : void
Parameters
- $manager : PluginManager
-
Plugin manager
Return values
void —setDbTableManager()
Set the table plugin manager.
public
setDbTableManager(PluginManager $manager) : void
Parameters
- $manager : PluginManager
-
Plugin manager
Return values
void —setLastExecuted()
Set last executed time for scheduled alert.
public
setLastExecuted(string $time) : mixed
Parameters
- $time : string
-
Time.
Tags
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 —setNotificationBaseUrl()
Set notification base URL.
public
setNotificationBaseUrl(string $notificationBaseUrl) : SearchEntityInterface
Parameters
- $notificationBaseUrl : string
-
Notification base URL
Return values
SearchEntityInterface —setNotificationFrequency()
Set notification frequency.
public
setNotificationFrequency(int $notificationFrequency) : SearchEntityInterface
Parameters
- $notificationFrequency : int
-
Notification frequency
Return values
SearchEntityInterface —setSaved()
Set saved.
public
setSaved(bool $saved) : SearchEntityInterface
Parameters
- $saved : bool
-
Saved
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
Return values
mixed —setSearchObject()
Set search object.
public
setSearchObject(Minified|null $searchObject) : SearchEntityInterface
Parameters
- $searchObject : Minified|null
-
Search object
Return values
SearchEntityInterface —setSessionId()
Set session identifier.
public
setSessionId(string|null $sessionId) : SearchEntityInterface
Parameters
- $sessionId : string|null
-
Session id
Return values
SearchEntityInterface —setTitle()
Set title.
public
setTitle(string|null $title) : SearchEntityInterface
Parameters
- $title : string|null
-
Title
Return values
SearchEntityInterface —setUser()
Set user.
public
setUser(UserEntityInterface|null $user) : SearchEntityInterface
Parameters
- $user : UserEntityInterface|null
-
User
Return values
SearchEntityInterface —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