-
Notifications
You must be signed in to change notification settings - Fork 25
/
Copy pathSoftDeletingModelInterface.php
57 lines (49 loc) · 1.1 KB
/
SoftDeletingModelInterface.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
<?php
namespace Esensi\Model\Contracts;
/**
* Soft Deleting Model Interface.
*
*/
interface SoftDeletingModelInterface
{
/**
* Force a hard delete on a soft deleted model.
*/
public function forceDelete();
/**
* Restore a soft-deleted model instance.
*
* @return bool|null
*/
public function restore();
/**
* Determine if the model instance has been soft-deleted.
*
* @return bool
*/
public function trashed();
/**
* Register a restoring model event with the dispatcher.
*
* @param Closure|string $callback
*/
public static function restoring($callback);
/**
* Register a restored model event with the dispatcher.
*
* @param Closure|string $callback
*/
public static function restored($callback);
/**
* Get the name of the "deleted at" column.
*
* @return string
*/
public function getDeletedAtColumn();
/**
* Get the fully qualified "deleted at" column.
*
* @return string
*/
public function getQualifiedDeletedAtColumn();
}