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
|
<?php
namespace AutomateWoo\Entity;
use LogicException;
/** * WorkflowTimingAbstract class. * * @since 5.1.0 * @package AutomateWoo\Entity */ abstract class WorkflowTimingBase implements WorkflowTiming {
const TYPE = '__TYPE__';
/** * Get the type of Workflow timing. * * @return string * @throws LogicException When a child class doesn't override the TYPE constant. */ public function get_type() { if ( static::TYPE === self::TYPE ) { throw new LogicException( sprintf( '%s must override the TYPE constant.', static::class ) ); }
return static::TYPE; } }
|