mirror of
https://gitee.com/ulthon/ulthon_admin.git
synced 2026-07-01 23:42:48 +08:00
33 lines
513 B
PHP
33 lines
513 B
PHP
<?php
|
|
|
|
namespace base\common\service;
|
|
|
|
use Exception;
|
|
|
|
class TestServiceBase
|
|
{
|
|
public const NAME = null;
|
|
|
|
public const DESC = null;
|
|
|
|
public const RUN = 'run';
|
|
|
|
public function getName()
|
|
{
|
|
if ($this::NAME === null) {
|
|
throw new Exception('name is not set');
|
|
}
|
|
|
|
return $this::NAME;
|
|
}
|
|
|
|
public function getDesc()
|
|
{
|
|
if ($this::DESC === null) {
|
|
throw new Exception('desc is not set');
|
|
}
|
|
|
|
return $this::DESC;
|
|
}
|
|
}
|