2021-11-02 16:01:24 +08:00
|
|
|
<?php
|
|
|
|
|
|
2022-03-15 18:05:33 +08:00
|
|
|
declare(strict_types=1);
|
|
|
|
|
|
2021-11-02 16:01:24 +08:00
|
|
|
namespace ZM\Module;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @since 2.6
|
|
|
|
|
*/
|
|
|
|
|
abstract class ModuleBase
|
|
|
|
|
{
|
|
|
|
|
protected $module_name;
|
|
|
|
|
|
|
|
|
|
protected $events = [];
|
|
|
|
|
|
2022-03-15 18:05:33 +08:00
|
|
|
public function __construct($module_name)
|
|
|
|
|
{
|
2021-11-02 16:01:24 +08:00
|
|
|
$this->module_name = $module_name;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* @return mixed
|
|
|
|
|
*/
|
2022-03-15 18:05:33 +08:00
|
|
|
public function getModuleName()
|
|
|
|
|
{
|
2021-11-02 16:01:24 +08:00
|
|
|
return $this->module_name;
|
|
|
|
|
}
|
|
|
|
|
|
2022-03-15 18:05:33 +08:00
|
|
|
public function getEvents(): array
|
|
|
|
|
{
|
2021-11-02 16:01:24 +08:00
|
|
|
return $this->events;
|
|
|
|
|
}
|
2022-03-15 18:05:33 +08:00
|
|
|
}
|