lightspeeddevelopment /
lsx-currencies
| 1 | <?php |
||
| 2 | /** |
||
| 3 | * LSX Currency Deprecated Main Class |
||
| 4 | * |
||
| 5 | * @package LSX Currencies |
||
| 6 | * @author LightSpeed |
||
| 7 | * @license GPL3 |
||
| 8 | * @link |
||
| 9 | * @copyright 2019 LightSpeed |
||
| 10 | */ |
||
| 11 | |||
| 12 | /** |
||
| 13 | * The main class |
||
| 14 | */ |
||
| 15 | class LSX_Currencies { |
||
| 16 | |||
| 17 | /** |
||
| 18 | * A wrapper for the deprecated class. |
||
| 19 | * |
||
| 20 | * @var object |
||
| 21 | */ |
||
| 22 | public $class = ''; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * Holds instance of the class |
||
| 26 | * |
||
| 27 | * @var object \lsx\currencies\classes\Currencies() |
||
| 28 | */ |
||
| 29 | private static $instance; |
||
| 30 | |||
| 31 | /** |
||
| 32 | * Constructor |
||
| 33 | */ |
||
| 34 | public function __construct() { |
||
|
0 ignored issues
–
show
Coding Style
introduced
by
Loading history...
|
|||
| 35 | $this->class = lsx_currencies(); |
||
| 36 | } |
||
|
0 ignored issues
–
show
|
|||
| 37 | |||
| 38 | /** |
||
| 39 | * Return an instance of this class. |
||
| 40 | * |
||
| 41 | * @return object |
||
| 42 | */ |
||
| 43 | public static function init() { |
||
| 44 | // If the single instance hasn't been set, set it now. |
||
| 45 | if ( ! isset( self::$instance ) ) { |
||
|
0 ignored issues
–
show
|
|||
| 46 | self::$instance = new self(); |
||
| 47 | } |
||
|
0 ignored issues
–
show
|
|||
| 48 | return self::$instance; |
||
| 49 | } |
||
|
0 ignored issues
–
show
|
|||
| 50 | } |
||
| 51 |