Passed
Push — analysis-zGno2k ( 620970 )
by Sudar
14:17 queued 42s
created

SchedulerAddon::register()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace BulkWP\BulkDelete\Core\Addon;
4
5
defined( 'ABSPATH' ) || exit; // Exit if accessed directly.
6
7
/**
8
 * Encapsulates the logic for a Scheduler add-on.
9
 *
10
 * All Scheduler add-ons will be extending this class.
11
 *
12
 * @since 6.0.0
13
 */
14
abstract class SchedulerAddon extends BaseAddon {
15
	/**
16
	 * Name of the Scheduler class.
17
	 *
18
	 * @var string
19
	 */
20
	protected $scheduler_class_name;
21
22
	/**
23
	 * Register and setup the add-on.
24
	 */
25
	public function register() {
26
		$scheduler = new $this->scheduler_class_name();
27
		$scheduler->register();
28
	}
29
}
30