@@ -80,7 +80,7 @@ |
||
| 80 | 80 | $format = strtolower($match[1]); |
| 81 | 81 | if (isset(self::$classTypes[$format])) { |
| 82 | 82 | $type = self::$classTypes[$format]; |
| 83 | - $class = "SwaggerGen\\Swagger\\Type\\{$type}Type"; |
|
| 83 | + $class = "SwaggerGen\\Swagger\\Type\\{$type}type"; |
|
| 84 | 84 | $this->Type = new $class($this, $definition); |
| 85 | 85 | } else { |
| 86 | 86 | $this->Type = new \SwaggerGen\Swagger\Type\ReferenceObjectType($this, $definition); |
@@ -48,10 +48,10 @@ discard block |
||
| 48 | 48 | */ |
| 49 | 49 | private $description; |
| 50 | 50 | |
| 51 | - /** |
|
| 52 | - * Whether property is read only |
|
| 53 | - * @var bool |
|
| 54 | - */ |
|
| 51 | + /** |
|
| 52 | + * Whether property is read only |
|
| 53 | + * @var bool |
|
| 54 | + */ |
|
| 55 | 55 | private $readOnly; |
| 56 | 56 | |
| 57 | 57 | /** |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | * @param \SwaggerGen\Swagger\AbstractObject $parent |
| 66 | 66 | * @param string $definition Either a built-in type or a definition name |
| 67 | 67 | * @param string $description description of the property |
| 68 | - * @param bool $readOnly Whether the property is read only |
|
| 68 | + * @param bool $readOnly Whether the property is read only |
|
| 69 | 69 | * @throws \SwaggerGen\Exception |
| 70 | 70 | */ |
| 71 | 71 | public function __construct(\SwaggerGen\Swagger\AbstractObject $parent, $definition, $description = null, $readOnly = null) |
@@ -130,7 +130,7 @@ discard block |
||
| 130 | 130 | |
| 131 | 131 | return self::arrayFilterNull(array_merge($valueType, array( |
| 132 | 132 | 'description' => empty($this->description) ? null : $this->description, |
| 133 | - 'readOnly' => $this->readOnly |
|
| 133 | + 'readOnly' => $this->readOnly |
|
| 134 | 134 | ), parent::toArray())); |
| 135 | 135 | } |
| 136 | 136 | |
@@ -51,10 +51,10 @@ discard block |
||
| 51 | 51 | */ |
| 52 | 52 | private $title = null; |
| 53 | 53 | |
| 54 | - /** |
|
| 55 | - * @var bool |
|
| 56 | - */ |
|
| 57 | - private $readOnly = null; |
|
| 54 | + /** |
|
| 55 | + * @var bool |
|
| 56 | + */ |
|
| 57 | + private $readOnly = null; |
|
| 58 | 58 | |
| 59 | 59 | /** |
| 60 | 60 | * @var \SwaggerGen\Swagger\Type\AbstractType |
@@ -118,7 +118,7 @@ discard block |
||
| 118 | 118 | return self::arrayFilterNull(array_merge($this->type->toArray(), array( |
| 119 | 119 | 'title' => empty($this->title) ? null : $this->title, |
| 120 | 120 | 'description' => empty($this->description) ? null : $this->description, |
| 121 | - 'readOnly' => $this->readOnly |
|
| 121 | + 'readOnly' => $this->readOnly |
|
| 122 | 122 | ), parent::toArray())); |
| 123 | 123 | } |
| 124 | 124 | |
@@ -127,9 +127,9 @@ discard block |
||
| 127 | 127 | return __CLASS__; |
| 128 | 128 | } |
| 129 | 129 | |
| 130 | - public function setReadOnly() |
|
| 131 | - { |
|
| 132 | - $this->readOnly = true; |
|
| 133 | - } |
|
| 130 | + public function setReadOnly() |
|
| 131 | + { |
|
| 132 | + $this->readOnly = true; |
|
| 133 | + } |
|
| 134 | 134 | |
| 135 | 135 | } |
@@ -49,11 +49,17 @@ |
||
| 49 | 49 | $this->dirs = $dirs; |
| 50 | 50 | } |
| 51 | 51 | |
| 52 | + /** |
|
| 53 | + * @param string $name |
|
| 54 | + */ |
|
| 52 | 55 | public function define($name, $value = 1) |
| 53 | 56 | { |
| 54 | 57 | $this->defines[$name] = $value; |
| 55 | 58 | } |
| 56 | 59 | |
| 60 | + /** |
|
| 61 | + * @param string $name |
|
| 62 | + */ |
|
| 57 | 63 | public function undefine($name) |
| 58 | 64 | { |
| 59 | 65 | unset($this->defines[$name]); |
@@ -14,7 +14,8 @@ |
||
| 14 | 14 | class testParse_MethodNonDoc |
| 15 | 15 | { |
| 16 | 16 | // @rest\method get something |
| 17 | - public function Method1() { |
|
| 17 | + public function Method1() |
|
| 18 | + { |
|
| 18 | 19 | |
| 19 | 20 | } |
| 20 | 21 | } |
@@ -17,7 +17,8 @@ |
||
| 17 | 17 | * Description of method |
| 18 | 18 | * @rest\description some description |
| 19 | 19 | */ |
| 20 | - public function Method1() { |
|
| 20 | + public function Method1() |
|
| 21 | + { |
|
| 21 | 22 | // @rest\method get something |
| 22 | 23 | } |
| 23 | 24 | } |
@@ -17,7 +17,8 @@ |
||
| 17 | 17 | * Description of method |
| 18 | 18 | * @rest\description some description |
| 19 | 19 | */ |
| 20 | - public function Method1() { |
|
| 20 | + public function Method1() |
|
| 21 | + { |
|
| 21 | 22 | |
| 22 | 23 | } |
| 23 | 24 | } |
@@ -18,7 +18,8 @@ |
||
| 18 | 18 | * @rest\description some description |
| 19 | 19 | * @rest\method get something |
| 20 | 20 | */ |
| 21 | - public function Method1() { |
|
| 21 | + public function Method1() |
|
| 22 | + { |
|
| 22 | 23 | |
| 23 | 24 | } |
| 24 | 25 | } |
@@ -15,7 +15,8 @@ |
||
| 15 | 15 | /** |
| 16 | 16 | * @rest\version 2 |
| 17 | 17 | */ |
| 18 | - public function Method1() { |
|
| 18 | + public function Method1() |
|
| 19 | + { |
|
| 19 | 20 | |
| 20 | 21 | } |
| 21 | 22 | |
@@ -7,7 +7,8 @@ |
||
| 7 | 7 | * @rest\title CurlyBraceFunction |
| 8 | 8 | * @rest\api MyApi Example |
| 9 | 9 | */ |
| 10 | -class testParse_CurlyBraces { |
|
| 10 | +class testParse_CurlyBraces |
|
| 11 | +{ |
|
| 11 | 12 | |
| 12 | 13 | /** |
| 13 | 14 | * @rest\endpoint /endpoint |