PHP code example of inphp / annotation
1. Go to this page and download the library: Download inphp/annotation library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
inphp / annotation example snippets
//先初始化
\Inphp\Annotation\Annotation::start();
//处理类的注解 $class 是已初始化的类, $method 可选,是本次类需要执行的方法
\Inphp\Annotation\Annotation::process($class, $method);
//请遵循 IAnnotation,实现 process 接口