@@ -62,7 +62,7 @@ |
||
62 | 62 | $apiDocBuilder->setVerboseOutput(true); |
63 | 63 | $apiDocBuilder->setDebugOutput(true); |
64 | 64 | } |
65 | - if($input->getOption('public-only')) { |
|
65 | + if ($input->getOption('public-only')) { |
|
66 | 66 | $apiDocBuilder->addExtension(PublicOnlyExtension::class); |
67 | 67 | } |
68 | 68 | $apiDocBuilder->build(); |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | $this->addH1(self::escape($trait->getFqsen())); |
40 | 40 | |
41 | 41 | $namespace = str_replace('\\' . $trait->getName(), '', $trait->getFqsen()); |
42 | - if($namespace !== '') { |
|
42 | + if ($namespace !== '') { |
|
43 | 43 | $this->beginPhpDomain('namespace', substr($namespace, 1), false); |
44 | 44 | } |
45 | 45 | |
@@ -69,7 +69,7 @@ discard block |
||
69 | 69 | foreach ($trait->getMethods() as $method) { |
70 | 70 | $docBlock = $method->getDocBlock(); |
71 | 71 | $params = []; |
72 | - if($docBlock !== null) { |
|
72 | + if ($docBlock !== null) { |
|
73 | 73 | /** @var Param $param */ |
74 | 74 | foreach ($docBlock->getTagsByName('param') as $param) { |
75 | 75 | $params[$param->getVariableName()] = $param; |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | /** @var Argument $argument */ |
80 | 80 | foreach ($method->getArguments() as $argument) { |
81 | 81 | // TODO: defaults, types |
82 | - $args .= ' $' . $argument->getName() . ', '; |
|
82 | + $args .= ' $' . $argument->getName() . ', '; |
|
83 | 83 | } |
84 | 84 | $args = substr($args, 0, -2); |
85 | 85 | |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | $modifiers .= $method->isStatic() ? ' static' : ''; |
90 | 90 | $this->addLine('.. rst-class:: ' . $modifiers)->addLine(); |
91 | 91 | $this->indent(); |
92 | - $this->beginPhpDomain('method', $method->getName().'('.$args.')'); |
|
92 | + $this->beginPhpDomain('method', $method->getName() . '(' . $args . ')'); |
|
93 | 93 | $this->addDocBlockDescription($docBlock); |
94 | 94 | if (!empty($params)) { |
95 | 95 | foreach ($method->getArguments() as $argument) { |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | $docBlock = $constant->getDocBlock(); |
56 | 56 | if ($docBlock) { |
57 | 57 | foreach ($docBlock->getTags() as $tag) { |
58 | - $this->addDocblockTag( $tag->getName(), $docBlock); |
|
58 | + $this->addDocblockTag($tag->getName(), $docBlock); |
|
59 | 59 | } |
60 | 60 | } |
61 | 61 | $this->endPhpDomain(); |
@@ -97,9 +97,9 @@ discard block |
||
97 | 97 | * @param $name string |
98 | 98 | * @param $indent bool Should indent after the section started |
99 | 99 | */ |
100 | - public function beginPhpDomain($type, $name, $indent=true) { |
|
100 | + public function beginPhpDomain($type, $name, $indent = true) { |
|
101 | 101 | // FIXME: Add checks if it is properly ended |
102 | - $this->addLine('.. php:' . $type . ':: '. $name)->addLine(); |
|
102 | + $this->addLine('.. php:' . $type . ':: ' . $name)->addLine(); |
|
103 | 103 | if ($indent === true) { |
104 | 104 | $this->indent(); |
105 | 105 | } |
@@ -108,7 +108,7 @@ discard block |
||
108 | 108 | /** |
109 | 109 | * @param string $type |
110 | 110 | */ |
111 | - public function endPhpDomain($type='') { |
|
111 | + public function endPhpDomain($type = '') { |
|
112 | 112 | $this->unindent(); |
113 | 113 | $this->addLine(); |
114 | 114 | } |
@@ -42,8 +42,8 @@ discard block |
||
42 | 42 | |
43 | 43 | $this->addH1(self::escape($class->getName())); |
44 | 44 | |
45 | - $namespace = substr($class->getFqsen(), 0, strlen($class->getFqsen())-strlen('\\' . $class->getName())); |
|
46 | - if($namespace !== '') { |
|
45 | + $namespace = substr($class->getFqsen(), 0, strlen($class->getFqsen()) - strlen('\\' . $class->getName())); |
|
46 | + if ($namespace !== '') { |
|
47 | 47 | $this->beginPhpDomain('namespace', substr($namespace, 1), false); |
48 | 48 | } |
49 | 49 | |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | $this->indent(); |
58 | 58 | $this->addDocBlockDescription($docBlock); |
59 | 59 | |
60 | - if($class instanceof Class_) { |
|
60 | + if ($class instanceof Class_) { |
|
61 | 61 | // Add class details |
62 | 62 | $parent = $class->getParent(); |
63 | 63 | if ($parent !== null) { |