fixed:云上传配置无法生效

This commit is contained in:
JaguarJack
2020-11-19 09:42:54 +08:00
parent e4a5ae0c37
commit 78e782dd01
10 changed files with 503 additions and 15 deletions

View File

@@ -0,0 +1,97 @@
<?php
namespace catcher\generate\build\classes;
use PhpParser\BuilderFactory;
class Properties
{
protected $propertyBuild;
public function __construct(string $name)
{
$this->propertyBuild = (new BuilderFactory())->property($name);
}
/**
* @time 2020年11月17日
* @return $this
*/
public function public()
{
$this->propertyBuild->makePublic();
return $this;
}
/**
* @time 2020年11月17日
* @return $this
*/
public function protected()
{
$this->propertyBuild->makeProtected();
return $this;
}
/**
* @time 2020年11月17日
* @return $this
*/
public function private()
{
$this->propertyBuild->makePrivate();
return $this;
}
/**
* 注释
*
* @time 2020年11月16日
* @param $comment
* @return $this
*/
public function static($comment)
{
$this->propertyBuild->makeStatic();
return $this;
}
/**
* set default
*
* @time 2020年11月16日
* @param $value
* @return $this
*/
public function default($value)
{
$this->propertyBuild->setDefault($value);
return $this;
}
public function type($type)
{
$this->propertyBuild->setType($type);
return $this;
}
public function docComment($comment)
{
$this->propertyBuild->setDocComment($comment);
return $this;
}
public function build()
{
return $this->propertyBuild;
}
}