1 | <?php |
||
12 | class DbAnonymizeCommand extends Command |
||
13 | { |
||
14 | use ConfirmableTrait; |
||
15 | |||
16 | /** |
||
17 | * The console command name. |
||
18 | * |
||
19 | * @var string |
||
20 | */ |
||
21 | protected $name = 'db:anonymize'; |
||
22 | |||
23 | /** |
||
24 | * The console command description. |
||
25 | * |
||
26 | * @var string |
||
27 | */ |
||
28 | protected $description = 'Anonymize the database'; |
||
29 | |||
30 | /** |
||
31 | * Get the console command options. |
||
32 | * |
||
33 | * @return array |
||
34 | */ |
||
35 | protected function getOptions() |
||
45 | |||
46 | public function handle() |
||
50 | |||
51 | /** |
||
52 | * Execute the console command. |
||
53 | * |
||
54 | * @return void |
||
55 | */ |
||
56 | public function fire() |
||
70 | |||
71 | /** |
||
72 | * Get an anonymizer instance from the container. |
||
73 | * |
||
74 | * @param CoreAnonymizer $coreAnonymizer |
||
75 | * |
||
76 | * @return AbstractAnonymizer |
||
77 | */ |
||
78 | protected function getAnonymizer($coreAnonymizer) |
||
84 | |||
85 | /** |
||
86 | * Get core anonymizer from parent package. |
||
87 | * |
||
88 | * @return CoreAnonymizer |
||
89 | */ |
||
90 | protected function getCoreAnonymizer() |
||
98 | |||
99 | /** |
||
100 | * Get database configuration from laravel config |
||
101 | * |
||
102 | * @param string $selected |
||
103 | * |
||
104 | * @return array |
||
105 | */ |
||
106 | protected function getDatabaseConfiguration($selected) |
||
118 | } |
||
119 |