tegic/constants

注解 枚举类

v1.0 2020-08-19 03:04 UTC

This package is auto-updated.

Last update: 2022-06-19 08:03:12 UTC


README

composer require tegic/constants

使用

定义

use tegic\Constants;

class Enum extends Constants
{
     /**
     * @Message("test")
     */
     CONST TEST = 1;
    /**
     * @Message("test1:%s,%s")
     */
     CONST TEST1 = 2;
}

使用

Enum::getMessage(Enum::TEST);
Enum::getMessage(Enum::TEST1,['1','2']);