class DatabaseReminderRepository implements ReminderRepositoryInterface (View source)

Methods

void
__construct( Connection $connection, string $table, string $hashKey, int $expires = 60)

Create a new reminder repository instance.

string
create( RemindableInterface $user)

Create a new reminder record and token.

bool
exists( RemindableInterface $user, string $token)

Determine if a reminder record exists and is valid.

void
delete( string $token)

Delete a reminder record by token.

void
deleteExpired()

Delete expired reminders.

string
createNewToken( RemindableInterface $user)

Create a new token for the user.

getConnection()

Get the database connection instance.

Details

at line line 45
void __construct( Connection $connection, string $table, string $hashKey, int $expires = 60)

Create a new reminder repository instance.

Parameters

Connection $connection
string $table
string $hashKey
int $expires

Return Value

void

at line line 59
string create( RemindableInterface $user)

Create a new reminder record and token.

Parameters

RemindableInterface $user

Return Value

string

at line line 105
bool exists( RemindableInterface $user, string $token)

Determine if a reminder record exists and is valid.

Parameters

RemindableInterface $user
string $token

Return Value

bool

at line line 143
void delete( string $token)

Delete a reminder record by token.

Parameters

string $token

Return Value

void

at line line 153
void deleteExpired()

Delete expired reminders.

Return Value

void

at line line 166
string createNewToken( RemindableInterface $user)

Create a new token for the user.

Parameters

RemindableInterface $user

Return Value

string

at line line 190
Connection getConnection()

Get the database connection instance.

Return Value

Connection