Completed
Push — feature/issue-67 ( f9f5f8...10fd4e )
by Mikaël
33:48
created
src/DomHandler/Wsdl/Tag/TagHeader.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
     const OPTIONAL_HEADER = 'optional';
13 13
     const ATTRIBUTE_REQUIRED = 'wsdl:required';
14 14
     /**
15
-     * @return TagInput|null
15
+     * @return \WsdlToPhp\PackageGenerator\DomHandler\AbstractNodeHandler|null
16 16
      */
17 17
     public function getParentInput()
18 18
     {
Please login to merge, or discard this patch.
src/Command/GeneratePackageCommand.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -110,7 +110,7 @@  discard block
 block discarded – undo
110 110
             $this->writeLn("  Generation not launched, use \"--force\" option to force generation");
111 111
             $this->writeLn(sprintf("  Generator's option file used: %s", $this->resolveGeneratorOptionsConfigPath()));
112 112
             $this->writeLn("  Used generator's options:");
113
-            $this->writeLn("    " . implode(PHP_EOL . '    ', $this->formatArrayForConsole($this->generatorOptions->toArray())));
113
+            $this->writeLn("    ".implode(PHP_EOL.'    ', $this->formatArrayForConsole($this->generatorOptions->toArray())));
114 114
         }
115 115
 
116 116
         $end = new \DateTime();
@@ -190,7 +190,7 @@  discard block
 block discarded – undo
190 190
      */
191 191
     private function formatArrayForConsole($array)
192 192
     {
193
-        array_walk($array, function (&$value, $index) {
193
+        array_walk($array, function(&$value, $index) {
194 194
             $value = sprintf("%s: %s", $index, !is_array($value) ? $value : implode(', ', $value));
195 195
         });
196 196
         return $array;
Please login to merge, or discard this patch.
src/Generator/Utils.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -151,11 +151,11 @@  discard block
 block discarded – undo
151 151
 
152 152
             $fileParts = pathinfo($origin);
153 153
             $fileBasename = (is_array($fileParts) && array_key_exists('basename', $fileParts)) ? $fileParts['basename'] : '';
154
-            $parts = parse_url(str_replace('/' . $fileBasename, '', $origin));
154
+            $parts = parse_url(str_replace('/'.$fileBasename, '', $origin));
155 155
             $scheme = (is_array($parts) && array_key_exists('scheme', $parts)) ? $parts['scheme'] : '';
156 156
             $host = (is_array($parts) && array_key_exists('host', $parts)) ? $parts['host'] : '';
157 157
             $path = (is_array($parts) && array_key_exists('path', $parts)) ? $parts['path'] : '';
158
-            $path = str_replace('/' . $fileBasename, '', $path);
158
+            $path = str_replace('/'.$fileBasename, '', $path);
159 159
             $pathParts = explode('/', $path);
160 160
             $finalPath = implode('/', $pathParts);
161 161
 
@@ -163,7 +163,7 @@  discard block
 block discarded – undo
163 163
                 if ($locationPart == '..') {
164 164
                     $finalPath = substr($finalPath, 0, strrpos($finalPath, '/', 0));
165 165
                 } else {
166
-                    $finalPath .= '/' . $locationPart;
166
+                    $finalPath .= '/'.$locationPart;
167 167
                 }
168 168
             }
169 169
 
@@ -172,7 +172,7 @@  discard block
 block discarded – undo
172 172
              * Remote file
173 173
              */
174 174
             if (!empty($scheme) && !empty($host)) {
175
-                $resolvedPath = str_replace('urn', 'http', $scheme) . '://' . $host . (!empty($port) ? ':' . $port : '') . str_replace('//', '/', $finalPath);
175
+                $resolvedPath = str_replace('urn', 'http', $scheme).'://'.$host.(!empty($port) ? ':'.$port : '').str_replace('//', '/', $finalPath);
176 176
             } elseif (empty($scheme) && empty($host) && count($pathParts)) {
177 177
                 /**
178 178
                  * Local file
Please login to merge, or discard this patch.
src/Generator/Generator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -601,7 +601,7 @@  discard block
 block discarded – undo
601 601
     {
602 602
         $destination = $this->options->getDestination();
603 603
         if (!empty($destination)) {
604
-            $destination = realpath($this->options->getDestination()) . DIRECTORY_SEPARATOR;
604
+            $destination = realpath($this->options->getDestination()).DIRECTORY_SEPARATOR;
605 605
         }
606 606
         return $destination;
607 607
     }
@@ -613,7 +613,7 @@  discard block
 block discarded – undo
613 613
     public function setOptionDestination($optionDestination)
614 614
     {
615 615
         if (!empty($optionDestination)) {
616
-            $this->options->setDestination(realpath($optionDestination) . DIRECTORY_SEPARATOR);
616
+            $this->options->setDestination(realpath($optionDestination).DIRECTORY_SEPARATOR);
617 617
         } else {
618 618
             throw new \InvalidArgumentException('Package\'s destination can\'t be empty', __LINE__);
619 619
         }
Please login to merge, or discard this patch.
src/Parser/Wsdl/AbstractParser.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
      */
132 132
     private function setSchemaAsParsed(Wsdl $wsdl, Schema $schema)
133 133
     {
134
-        $key = $wsdl->getName() . $schema->getName();
134
+        $key = $wsdl->getName().$schema->getName();
135 135
         if (!array_key_exists($key, $this->parsedSchemas)) {
136 136
             $this->parsedSchemas[$key] = array();
137 137
         }
@@ -145,7 +145,7 @@  discard block
 block discarded – undo
145 145
      */
146 146
     public function isSchemaParsed(Wsdl $wsdl, Schema $schema)
147 147
     {
148
-        $key = $wsdl->getName() . $schema->getName();
148
+        $key = $wsdl->getName().$schema->getName();
149 149
         return
150 150
             array_key_exists($key, $this->parsedSchemas) &&
151 151
             is_array($this->parsedSchemas[$key]) &&
Please login to merge, or discard this patch.
src/DomHandler/Wsdl/Tag/AbstractTag.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
         if ($this->getParent() instanceof AbstractNodeHandler) {
29 29
             $parentTags = $strict ? $additionalTags : $this->getSuitableParentTags($additionalTags);
30 30
             $parentNode = $this->getParent()->getNode();
31
-            while ($maxDeep-- > 0 && ($parentNode instanceof \DOMElement) && !empty($parentNode->nodeName) && (!preg_match('/' . implode('|', $parentTags) . '/i', $parentNode->nodeName) || ($checkName && preg_match('/' . implode('|', $parentTags) . '/i', $parentNode->nodeName) && (!$parentNode->hasAttribute('name') || $parentNode->getAttribute('name') === '')))) {
31
+            while ($maxDeep-- > 0 && ($parentNode instanceof \DOMElement) && !empty($parentNode->nodeName) && (!preg_match('/'.implode('|', $parentTags).'/i', $parentNode->nodeName) || ($checkName && preg_match('/'.implode('|', $parentTags).'/i', $parentNode->nodeName) && (!$parentNode->hasAttribute('name') || $parentNode->getAttribute('name') === '')))) {
32 32
                 $parentNode = $parentNode->parentNode;
33 33
             }
34 34
             if ($parentNode instanceof \DOMElement) {
Please login to merge, or discard this patch.
src/ConfigurationReader/StructArrayReservedMethod.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -26,6 +26,6 @@
 block discarded – undo
26 26
      */
27 27
     public static function getDefaultArrayConfigurationPath()
28 28
     {
29
-        return dirname(__FILE__) . '/../resources/config/struct_array_reserved_keywords.yml';
29
+        return dirname(__FILE__).'/../resources/config/struct_array_reserved_keywords.yml';
30 30
     }
31 31
 }
Please login to merge, or discard this patch.
src/ConfigurationReader/StructReservedMethod.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,6 +18,6 @@
 block discarded – undo
18 18
      */
19 19
     public static function getDefaultConfigurationPath()
20 20
     {
21
-        return dirname(__FILE__) . '/../resources/config/struct_reserved_keywords.yml';
21
+        return dirname(__FILE__).'/../resources/config/struct_reserved_keywords.yml';
22 22
     }
23 23
 }
Please login to merge, or discard this patch.
src/ConfigurationReader/PhpReservedKeyword.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,6 +18,6 @@
 block discarded – undo
18 18
      */
19 19
     public static function getDefaultConfigurationPath()
20 20
     {
21
-        return dirname(__FILE__) . '/../resources/config/php_reserved_keywords.yml';
21
+        return dirname(__FILE__).'/../resources/config/php_reserved_keywords.yml';
22 22
     }
23 23
 }
Please login to merge, or discard this patch.