1
|
|
|
<?php |
2
|
|
|
/* |
3
|
|
|
* This file is part of the Backup package, an RunOpenCode project. |
4
|
|
|
* |
5
|
|
|
* (c) 2015 RunOpenCode |
6
|
|
|
* |
7
|
|
|
* For the full copyright and license information, please view the LICENSE |
8
|
|
|
* file that was distributed with this source code. |
9
|
|
|
* |
10
|
|
|
* This project is fork of "kbond/php-backup", for full credits info, please |
11
|
|
|
* view CREDITS file that was distributed with this source code. |
12
|
|
|
*/ |
13
|
|
|
namespace RunOpenCode\Backup\Event; |
14
|
|
|
|
15
|
|
|
/** |
16
|
|
|
* Class BackupEvents |
17
|
|
|
* |
18
|
|
|
* Backup events. |
19
|
|
|
* |
20
|
|
|
* @package RunOpenCode\Backup\Event |
21
|
|
|
*/ |
22
|
|
|
final class BackupEvents |
23
|
|
|
{ |
24
|
|
|
/** |
25
|
|
|
* Dispatched always at the begging of the backup process. |
26
|
|
|
*/ |
27
|
|
|
const BEGIN = 'run_open_code.backup.begin'; |
28
|
|
|
|
29
|
|
|
/** |
30
|
|
|
* Dispatched after Source have provided backup files. |
31
|
|
|
*/ |
32
|
|
|
const FETCH = 'run_open_code.backup.fetch'; |
33
|
|
|
|
34
|
|
|
/** |
35
|
|
|
* Dispatched after Processor have finished with processing. |
36
|
|
|
*/ |
37
|
|
|
const PROCESS = 'run_open_code.backup.process'; |
38
|
|
|
|
39
|
|
|
/** |
40
|
|
|
* Dispatched after Namer have finished with naming of backup. |
41
|
|
|
*/ |
42
|
|
|
const NAME = 'run_open_code.backup.name'; |
43
|
|
|
|
44
|
|
|
/** |
45
|
|
|
* Dispatched after PreRotator have nominated backups for rotation. |
46
|
|
|
*/ |
47
|
|
|
const PRE_ROTATE = 'run_open_code.backup.pre_rotate'; |
48
|
|
|
|
49
|
|
|
/** |
50
|
|
|
* Dispatched after backup is pushed to Destination. |
51
|
|
|
*/ |
52
|
|
|
const PUSH = 'run_open_code.backup.push'; |
53
|
|
|
|
54
|
|
|
/** |
55
|
|
|
* Dispatched after PostRotator have nominated backups for rotation. |
56
|
|
|
*/ |
57
|
|
|
const POST_ROTATE = 'run_open_code.backup.post_rotate'; |
58
|
|
|
|
59
|
|
|
/** |
60
|
|
|
* Dispatched always - when backup process is terminated. |
61
|
|
|
*/ |
62
|
|
|
const TERMINATE = 'run_open_code.backup.terminate'; |
63
|
|
|
|
64
|
|
|
/** |
65
|
|
|
* Dispatched on backup error. |
66
|
|
|
*/ |
67
|
|
|
const ERROR = 'run_open_code.backup.error'; |
68
|
|
|
|
69
|
|
|
private function __construct() { /* noop */} |
70
|
|
|
} |
71
|
|
|
|