Comments
extends RowGateway
in package
implements
CommentsEntityInterface, DbServiceAwareInterface
Uses
DbServiceAwareTrait
Row Definition for comments
Tags
Interfaces, Classes, Traits and Enums
- CommentsEntityInterface
- Entity model interface for comments table
- DbServiceAwareInterface
- Marker interface for classes that depend on the \VuFind\Db\Service\PluginManager
Table of Contents
- $comment : string
- $created : string
- $id : int
- $resource_id : int
- $user_id : int|null
- $dbServiceManager : PluginManager
- Database service plugin manager
- __construct() : mixed
- Constructor
- getComment() : string
- Comment getter
- getCreated() : DateTime
- Created getter
- getDbService() : T
- Get a database service object.
- getDbServiceManager() : PluginManager
- Get the service plugin manager. Throw an exception if it is missing.
- getId() : int
- Id getter
- getPrimaryKeyColumn() : array<string|int, mixed>
- Retrieve primary key information.
- getUser() : UserEntityInterface|null
- User getter
- setComment() : Comments
- Comment setter
- setCreated() : Comments
- Created setter.
- setDbServiceManager() : void
- Set the service plugin manager.
- setResource() : Comments
- Resource setter.
- setUser() : Comments
- User setter.
Properties
$comment
public
string
$comment
$created
public
string
$created
$id
public
int
$id
$resource_id
public
int
$resource_id
$user_id
public
int|null
$user_id
$dbServiceManager
Database service plugin manager
protected
PluginManager
$dbServiceManager
Methods
__construct()
Constructor
public
__construct(Adapter $adapter) : mixed
Parameters
- $adapter : Adapter
-
Database adapter
Return values
mixed —getComment()
Comment getter
public
getComment() : string
Return values
string —getCreated()
Created getter
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 —getId()
Id getter
public
getId() : int
Return values
int —getPrimaryKeyColumn()
Retrieve primary key information.
public
getPrimaryKeyColumn() : array<string|int, mixed>
Return values
array<string|int, mixed> —getUser()
User getter
public
getUser() : UserEntityInterface|null
Return values
UserEntityInterface|null —setComment()
Comment setter
public
setComment(string $comment) : Comments
Parameters
- $comment : string
-
Comment
Return values
Comments —setCreated()
Created setter.
public
setCreated(DateTime $dateTime) : Comments
Parameters
- $dateTime : DateTime
-
Created date
Return values
Comments —setDbServiceManager()
Set the service plugin manager.
public
setDbServiceManager(PluginManager $manager) : void
Parameters
- $manager : PluginManager
-
Plugin manager
Return values
void —setResource()
Resource setter.
public
setResource(ResourceEntityInterface $resource) : Comments
Parameters
- $resource : ResourceEntityInterface
-
Resource id.
Return values
Comments —setUser()
User setter.
public
setUser(UserEntityInterface|null $user) : Comments
Parameters
- $user : UserEntityInterface|null
-
User that created comment