for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php declare(strict_types=1);
/**
* It's free open-source software released under the MIT License.
*
* @author Anatoly Fenric <[email protected]>
* @copyright Copyright (c) 2018, Anatoly Fenric
* @license https://github.com/sunrise-php/http-router/blob/master/LICENSE
* @link https://github.com/sunrise-php/http-router
*/
namespace Sunrise\Http\Router\Annotation\OpenApi;
* @Annotation
* @Target({"ANNOTATION"})
final class Property
{
* @Required
* @var string
public $name;
* @Enum({"string", "number", "integer", "boolean", "array", "object"})
public $type;
* @var bool
public $deprecated = false;
public $readOnly = false;
public $writeOnly = false;
public $nullable = false;
* @return array
public function toArray() : array
$result = [
'type' => $this->type,
'deprecated' => $this->deprecated,
'readOnly' => $this->readOnly,
'writeOnly' => $this->writeOnly,
'nullable' => $this->nullable,
];
return $result;
}