2020-12-18 11:35:35 +08:00
|
|
|
<?php
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
namespace Annotation\Route;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Class Document
|
|
|
|
|
* @package Annotation\Route
|
|
|
|
|
*/
|
|
|
|
|
#[\Attribute(\Attribute::TARGET_METHOD)] class Document
|
|
|
|
|
{
|
|
|
|
|
|
2020-12-18 11:55:16 +08:00
|
|
|
const INTEGER = 'int';
|
|
|
|
|
const STRING = 'string';
|
|
|
|
|
const BOOLEAN = 'bool';
|
|
|
|
|
const FLOAT = 'float';
|
|
|
|
|
|
|
|
|
|
const ALIAS = [
|
|
|
|
|
self::INTEGER => '整数',
|
|
|
|
|
self::STRING => '字符串',
|
|
|
|
|
self::BOOLEAN => '布尔值',
|
|
|
|
|
self::FLOAT => '浮点',
|
|
|
|
|
];
|
|
|
|
|
|
|
|
|
|
|
2020-12-18 11:35:35 +08:00
|
|
|
public function __construct(
|
2020-12-18 16:46:10 +08:00
|
|
|
public array $request,
|
2020-12-18 16:45:12 +08:00
|
|
|
public array $response
|
2020-12-18 11:35:35 +08:00
|
|
|
)
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|